chairemobilite / transition

Transition is a modern new approach to transit planning. It's a web application to model, simulate and plan public transit and alternative transportation.
http://transition.city
MIT License
20 stars 13 forks source link

It should not be possible to import nodes at the exact same location as another #908

Closed kaligrafy closed 2 months ago

kaligrafy commented 2 months ago

even if the parameter says to not merge node on import in the GTFS import or any other node import tool.

greenscientist commented 2 months ago

@kaligrafy so what should be the behavior ? Merging them anyway with a warning? Rejecting the operation? Adding a note to the node information ?

kaligrafy commented 2 months ago

Just merge. If the info is the same, just merge without warning, if there is mismmatch, we should warn the user with a popup saying: Some nodes have the same coordinates as existing nodes, but with different attributes. What should we do with these attributes? [use imported attributes | use existing attributes | cancel]. Note that the cancel button could be quite complicated to process though.

tahini commented 2 months ago

I can reproduce this, for some GTFS with 200 nodes, 30 are constantly re-imported. It's because the nodes collection does not even detect them as within bird radius of each other. It works for the 170 others.

tahini commented 2 months ago

Turns out the local index, using geokdbush does not return those nodes when getting the nodes withing bird distance for those 30 repeated ones. If we use postgis instead, with st_dwithin, it works