Open Erudition opened 5 months ago
Here's the offending line: https://github.com/GIScience/orstools-qgis-plugin/blob/2b981c177fc67ba9f0ea7b05d53a13d1298610fc/ORStools/common/networkaccessmanager.py#L318 It seems to be concatenating the error message (string) with the reply data which is apparently bytes.
I tried changing it to just:
errString = self.reply.errorString()
Which moved the error:
RuntimeError: wrapped C/C++ object of type QNetworkReply has been deleted
Traceback (most recent call last):
File "/home/adroit/.local/share/QGIS/QGIS3/profiles/default/python/plugins/ORStools/common/networkaccessmanager.py", line 297, in replyFinished
err = self.reply.error()
RuntimeError: wrapped C/C++ object of type QNetworkReply has been deleted
to an earlier line: https://github.com/GIScience/orstools-qgis-plugin/blob/2b981c177fc67ba9f0ea7b05d53a13d1298610fc/ORStools/common/networkaccessmanager.py#L297
Hi,
interesting use case. You're running your own local ORS instance? Have you set maximum_intervals
to a custom value? This is hard to reproduce without more information on your setup. Please provide us with some more.
Best regards
Yep, running it locally as stated. Can't process isochrones this big with the public instance.
Darn, I was hoping we could improve the durability of the code based on these details alone, given that asking concatenating bytes to a string is apparently possible currently and shouldn't be. I've changed my setup significantly in the time before your reply, and I managed to get it to work by changing the OSM pbr file (evidently some stations were in Canada whereas the OSM data I had was only the US). The error has appeared in several other cases with varying setup, I'll see if I can remember the way my config file was set when it triggered so you can reproduce it.
Here's what I did
Calculating an isochrones layer, to form a heatmap of driving distance from/to each of the public Compressed Natural Gas (CNG) Stations in North America. This can determine the areas that I should not drive to with my CNG vehicle, as I would run out of fuel before I can get back to a station. I used increments of 10 miles, up to 150 (the theoretical max of my tank), so I needed to run the ORS tool locally.
The resulting database was not openable, all I could determine was this Python warning which repeated hundreds of times:
Here's what I got
Here's what I was expecting
A valid gpkg file produced and a rendered heatmap layer.
Here's what I think could be improved