iD icon indicating copy to clipboard operation
iD copied to clipboard

:bug: Warn on same layer crossing regardless of bridge / tunnel

Open homersimpsons opened this issue 8 months ago • 2 comments

Fixes #10631

homersimpsons avatar Apr 26 '25 21:04 homersimpsons

Shoutout to the project, it was really easy to setup a dev environment on GitHub Codespace and run iD and its test!

Here you can see the new check working: image

  • One way is a bridge, the other is not
  • Both have the same defined layer
  • => The warning is raised

homersimpsons avatar Apr 26 '25 21:04 homersimpsons

Should I improve / change anything here?

This is something for Martin to review IMO.

Looks like I cannot assign you @tyrasd

homersimpsons avatar May 15 '25 18:05 homersimpsons

@tyrasd do you want me to do anything to help getting this merged? Like adding tests? Feel free to asks and possibly suggest some changes.

To sum up a bit the changes:

  1. The main change is to warn if 2 elements have the same defined layer and intersect
  2. I rewrote the tunnel / bridge part to be more concise and explicit (and to remove the case that is already handled by (1))
  3. The building part is already included in the more general check (1) as discussed in https://github.com/openstreetmap/iD/pull/10999#discussion_r2063755697
  4. I added 2 tests for the above changes, all the other tests are untouched

homersimpsons avatar Jul 08 '25 11:07 homersimpsons

if there are no objections, i think this could be merged

k-yle avatar Jul 13 '25 06:07 k-yle