Directions from points 1 layer with fixed start and end point

Hi, I’m testing a local install of openrouteservice with docker, when I use the Directions from points 1 layer function the server works fine, but when I add the option “with fixed start and end point” the system crashes. If I use the same option with the online service the system does not give an error, so I supesct the the error is in Docker configuration and not in my files. Does anyone know how to fix this error? Thank you. Below is the error code:

Versione di QGIS: 3.24.2-Tisler
Revisione codice QGIS: 13c1a028
Versione di Qt: 5.15.2
Versione Python: 3.9.5
Versione di GDAL: 3.4.2
Versione di GEOS: 3.10.2-CAPI-1.16.0
Versione di PROJ: Rel. 9.0.0, March 1st, 2022
versione di PDAL: 2.3.0 (git-version: 1c17a7)
Algoritmo iniziato alle: 2023-03-09T11:22:58
In avvio l'algoritmo 'Directions from points 1 layer' …
Parametri in ingresso:
{ 'INPUT_AVOID_BORDERS' : None, 'INPUT_AVOID_COUNTRIES' : '', 'INPUT_AVOID_FEATURES' : [], 'INPUT_AVOID_POLYGONS' : None, 'INPUT_LAYER_FIELD' : 'ORS_ID', 'INPUT_OPTIMIZE' : 3, 'INPUT_POINT_LAYER' : QgsProcessingFeatureSourceDefinition('D:/CLOUD/FORMULAMBIENTE/UFFICIO-PROGETTAZIONE-LOCALE/PROGETTI GIS/LAZIO/CAMPANE ROMA/CAMPANE-PROGETTO.shp|subset="LOTTO" = \'LOTTO 07\' OR "GIORNO" = 99', selectedFeaturesOnly=True, featureLimit=-1, geometryCheck=QgsFeatureRequest.GeometryAbortOnInvalid), 'INPUT_PREFERENCE' : 0, 'INPUT_PROFILE' : 0, 'INPUT_PROVIDER' : 1, 'INPUT_SORTBY' : '', 'OUTPUT' : 'TEMPORARY_OUTPUT' }

Traceback (most recent call last):
File "C:\Users/...../AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\ORStools\common\client.py", line 157, in request
response, content = self.nam.request(self.url,
File "C:\Users/...../AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\ORStools\common\networkaccessmanager.py", line 263, in request
raise self.http_call_result.exception
ORStools.common.networkaccessmanager.RequestsException: Network error #404: Error transferring http://localhost:8080/ors/optimization? - server replied: 

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "C:\Users/...../AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\ORStools\common\client.py", line 167, in request
self._check_status()
File "C:\Users/...../AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\ORStools\common\client.py", line 223, in _check_status
raise exceptions.ApiError(
ORStools.utils.exceptions.ApiError: 404 (Network error #404: Error transferring http://localhost:8080/ors/optimization? - server replied: )

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "C:\Users/...../AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\ORStools\proc\directions_points_layer_proc.py", line 163, in processAlgorithm
response = ors_client.request('/optimization', {}, post_json=params)
File "C:\Users/...../AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\ORStools\common\client.py", line 179, in request
logger.log(f"Feature ID {post_json['id']} caused a {e.__class__.__name__}: {str(e)}", 2)
KeyError: 'id'

Execution failed after 0.12 secondi

Caricamento layer
Algoritmo 'Directions from points 1 layer' terminato

Hey,

this is not an issue with the docker configuration.
When using the Traveling Salesman option, this will produce an optimization request.

The /optimization-endpoint is not part of the openrouteservice, but stems from the VROOM-project.

Best regards

Hi, thanks for the clarification. I’ll try to study the VROOM project documentation.
Best regards
A.

1 Like

Hello @Andrea_Mancuso,

Did you find out how to use that option ?
I’d like to user the Traveler Salesman feature, but it gives me an error :

Traceback (most recent call last):
File "/QGIS/QGIS3\profiles\default/python/plugins\ORStools\common\client.py", line 159, in request
response, content = self.nam.request(
File "/QGIS/QGIS3\profiles\default/python/plugins\ORStools\common\networkaccessmanager.py", line 276, in request
raise self.http_call_result.exception
ORStools.common.networkaccessmanager.RequestsException: Network error #400: Error transferring https://api.openrouteservice.org/optimization? - server replied: Bad Request

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/QGIS/QGIS3\profiles\default/python/plugins\ORStools\common\client.py", line 167, in request
self._check_status()
File "/QGIS/QGIS3\profiles\default/python/plugins\ORStools\common\client.py", line 229, in _check_status
raise exceptions.ApiError(str(status_code), message)
ORStools.utils.exceptions.ApiError: 400 ({"code":2,"error":"Duplicate job id: 8."}
)

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/QGIS/QGIS3\profiles\default/python/plugins\ORStools\proc\directions_points_layer_proc.py", line 168, in processAlgorithm
response = ors_client.request("/optimization", {}, post_json=params)
File "/QGIS/QGIS3\profiles\default/python/plugins\ORStools\common\client.py", line 179, in request
f"Feature ID {post_json['id']} caused a {e.__class__.__name__}: {str(e)}", 2
KeyError: 'id'