You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
While working on #4589, I found a tricky bug in actionJoinWays.
This code uses osmJoinWays to get the joined nodelist. Unfortunately osmJoinWays has a side effect that it sometimes needs to reverse the ways in order to join them properly. Reversing a way might change the tags of the way, the order of the nodes, but also adjust the tags on the child nodes.
The reversed ways and nodes never get replaced into the graph, and the code after osmJoinWays continues working with the original immutable survivor way, when really we need to perform those reversal actions.
Here is a case where we join two ways (Left, Right). Both ways have directional stop signs. What should happen is that osmJoinWays should reverse any tags on the Right way and the Right stop sign so that it continues to face East. (osmJoinWays actually does call actionReverse internally, but it doesn't persist the results of that into the graph. It should not update the graph, but it should return those actions so that the caller can do it if needed).
The text was updated successfully, but these errors were encountered:
While working on #4589, I found a tricky bug in
actionJoinWays
.This code uses
osmJoinWays
to get the joined nodelist. UnfortunatelyosmJoinWays
has a side effect that it sometimes needs to reverse the ways in order to join them properly. Reversing a way might change the tags of the way, the order of the nodes, but also adjust the tags on the child nodes.iD/modules/actions/join.js
Lines 40 to 44 in fdf1fa4
The reversed ways and nodes never get replaced into the graph, and the code after
osmJoinWays
continues working with the original immutablesurvivor
way, when really we need to perform those reversal actions.Here is a case where we join two ways (Left, Right). Both ways have directional stop signs. What should happen is that
osmJoinWays
should reverse any tags on the Right way and the Right stop sign so that it continues to face East. (osmJoinWays
actually does callactionReverse
internally, but it doesn't persist the results of that into the graph. It should not update the graph, but it should return those actions so that the caller can do it if needed).The text was updated successfully, but these errors were encountered: