iD icon indicating copy to clipboard operation
iD copied to clipboard

iD suggests hashtags as a key on objects

Open simonpoole opened this issue 1 month ago • 7 comments

How to reproduce the issue?

iD will suggest hashtags as a key on OSM objects even though this is a tag key that should be limited to changesets.

Screenshot(s) or anything else?

Image

Which deployed environments do you see the issue in?

Released version at openstreetmap.org/edit

What version numbers does this issue effect?

2.37.3

Which browsers are you seeing this problem on?

Other (please specify) browser independent.

simonpoole avatar Nov 29 '25 17:11 simonpoole

Looks like a prefix search for “has” on taginfo picked up the 150 or so occurrences of this key on elements. (taginfo doesn’t track changeset tags.)

At a glance, some of the occurrences are probably unrelated to the meaning on changesets, some sort of any-tag-you-like for saying the social media hashtag associated with a POI. But I also see a bunch of POIs tagged by Central Washington University. If it was an editor bug at any point, I think this key would be more widespread, but it’s probably someone misunderstanding the instructions they were given.

1ec5 avatar Nov 30 '25 00:11 1ec5

It does turn up in the iD presets labeled as a changeset tag so I was more suspecting an issue with handling that.

simonpoole avatar Nov 30 '25 09:11 simonpoole

Hi @simonpoole I would like to work on this issue. Can you please assign it to me?

ritiksingh3202 avatar Dec 05 '25 12:12 ritiksingh3202

the code already filters out tags with less than 2500 uses, but there is an exception for low-use tags that have a wiki page. Which is why hashtags appears.

https://github.com/openstreetmap/iD/blob/50250f23d9fa8b3c53c84bfba55b77b4f282ad50/modules/services/taginfo.js#L79

this could be fixed by creating a new RegExp like this, but for keys instead of values:

https://github.com/openstreetmap/iD/blob/50250f23d9fa8b3c53c84bfba55b77b4f282ad50/modules/services/taginfo.js#L16

k-yle avatar Dec 05 '25 13:12 k-yle

the code already filters out tags with less than 2500 uses, but there is an exception for low-use tags that have a wiki page.

A bit OT but I would note that that is not a useful criteria any more at all since people have been adding wiki pages for tags that don't have wiki pages.

More specific to this case, I don't understand why it isn't filtered out based on the information in iDs presets see https://github.com/openstreetmap/iD/issues/11625#issuecomment-3592410049

simonpoole avatar Dec 05 '25 13:12 simonpoole

More specific to this case, I don't understand why it isn't filtered out based on the information in iDs presets

These suggestions come purely from taginfo, presets are not considered at all. Theoretically, this issue could be solved by checking the presets for usage=changeset, but that approach would unexpectedly match source, due to https://github.com/openstreetmap/id-tagging-schema/pull/1508

k-yle avatar Dec 05 '25 13:12 k-yle

Hi @simonpoole I would like to work on this issue. Can you please assign it to me?

I'm not a maintainer of this repo, so can't really help with that.

simonpoole avatar Dec 05 '25 14:12 simonpoole