Surface= duplicated by paved= - bot edit proposal

there are some paved=no combined with surface values such as say surface=dirt that indicate that surface is not paved

there are some paved=yes combined with surface values such as say surface=asphalt that indicate that surface is paved

I propose to remove such paved= values as not needed - and likely to cause confusion if someone would retag surface=

paved= without surface= will not be edited

paved= conflicting with surface= will not be edited

23 Likes

My usual question with this sort of edit - how does a bot edit like this improve the quality of OSM data?

1 Like

Previously unpaved way gets paved with asphalt, StreetComplete user changes surface=gravel to surface=asphalt without being aware of (i.e. without editing) paved=no → confusion

4 Likes

it makes data less confusing, especially if surface= is later edited again

surface=paved paved=yes is duplicative and mildly confusing, if you get surface=paved paved=no you need to start looking at data what is going on

so it is better to clean it while it is merely duplication

also, it makes easier to manually investigate remaining paved=

And that was how this proposal was triggered - after several cases where human brain was not really needed I looked into it and scale is large enough to make mass edit worthwhile.

13 Likes

Sounds good, though I would also be OK with moving paved=yes to surface=paved if there is no surface=* tag already.

6 Likes

I plan to look into it, but first would need to process decent sample of cases to check is it safe (often I run out of cases before I checked enough to be sure that bot edit makes sense)

2 Likes

Submitted to OSM Weekly ( submission OSMBC )

was submitted by me as

Mateusz Konieczny proposed to remove paved= values duplicating surface= info (bot edit proposal)

and was edited not by me to

Mateusz Konieczny is proposing a mechanical edit to fix conflicting paved=* and surface=* tags.

1 Like

There is also surface=unpaved, so paved=no could be moved to surface=unpaved iff no surface is tagged yet.

There are only 2589 uses of paved=* in total. 2378 of those are no or yes. The remainder are mostly values like asphalt or unpavedwhich could be moved to the surface tag iff there are no conflicts.

The wiki page Key:paved - OpenStreetMap Wiki has been a redirect to Key:surface - OpenStreetMap Wiki since 2010.

I agree that removing duplicate information will reduce confusion. An automated edit should be able to remove almost all occurences of paved=* and the few remaining ones (i.e. conflicts) need to be investigated manually.

4 Likes

Mechanical Edits/Mateusz Konieczny - bot account/remove paved key duplicating surface key - OpenStreetMap Wiki is up

3 Likes
    run_simple_retagging_task(
        max_count_of_elements_in_one_changeset=500,
        objects_to_consider_query=query,
        cache_folder_filepath='/media/mateusz/OSM_cache/osm_bot_cache',
        is_in_manual_mode=True,
        changeset_comment='remove not needed paved=yes duplicating normal surface= tag',
        discussion_url=None,
        osm_wiki_documentation_page=None,
        edit_element_function=edit_element,
    )

Is there a reason that the “paved=yes” version doesn’t have a discussion_url or osm_wiki_documentation_page? The “paved=no” version does have them:

    run_simple_retagging_task(
        max_count_of_elements_in_one_changeset=500,
        objects_to_consider_query=query,
        cache_folder_filepath='/media/mateusz/OSM_cache/osm_bot_cache',
        is_in_manual_mode=False,
        changeset_comment='remove not needed paved=no duplicating normal surface= tag',
        discussion_url="https://community.openstreetmap.org/t/surface-duplicated-by-paved-bot-edit-proposal/138817",
        osm_wiki_documentation_page="https://wiki.openstreetmap.org/w/index.php?title=Mechanical_Edits/Mateusz_Konieczny_-_bot_account/remove_paved_key_duplicating_surface_key",
        edit_element_function=edit_element,
    )
1 Like

bad news: it is a bug

good news: I am fixing it right now

also good news: bug would be caught at runtime

my library would run it in manual mode, not in bot mode

and if bot mode would be set (is_in_manual_mode=False) it would stop with error in case of discussion_url or osm_wiki_documentation_page set to empty None