Opened 3 months ago
Last modified 3 months ago
#23996 new enhancement
Convert non-standard dashes to standard dashes in the Opening Hours field
Reported by: | matheusgomesms | Owned by: | team |
---|---|---|---|
Priority: | normal | Milestone: | |
Component: | Core validator | Version: | |
Keywords: | template_report opening_hours dash | Cc: | SimonPoole |
Description
Please check v3: https://www.openstreetmap.org/way/1169560087
What steps will reproduce the problem?
Upload opening hours using a non-standard dash
the standard dash seems to be - (Hyphen-Minus)
other similar dashes:
‐ HYPHEN
‑ NON-BREAKING HYPHEN
‒ FIGURE DASH
– EN DASH
﹘SMALL EM DASH
۔ ARABIC FULL STOP
⁃ HYPHEN BULLET
˗ MODIFIER LETTER MINUS SIGN
− MINUS SIGN
➖ HEAVY MINUS SIGN
Ⲻ COPTIC CAPITAL LETTER DIALECT-P NI
(similar characters found from https://www.unicode.org/Public/security/15.0.0/confusables.txt, there may be more)
This leads to parsing fails in some applications, eg. also see https://github.com/organicmaps/organicmaps/issues/3888. It should also be handled at the application level, but it's good to have standard data as well.
iD suffers same problem: https://github.com/openstreetmap/iD/issues/9735
What is the expected result?
For example, JOSM could fix it while editing. If a user types or pastes any type of non-standard dash, JOSM could replace it with standard dash immediately, or throw a warning on the validator.
What happens instead?
Nothing, it is uploaded without fix or warning.
Please provide any additional information below. Attach a screenshot if possible.
Used latest version (19253).
Attachments (0)
Change History (3)
comment:1 by , 3 months ago
comment:2 by , 3 months ago
Component: | Core → Core validator |
---|---|
Keywords: | opening_hours dash added |
Type: | defect → enhancement |
I do not think we have the system to properly replace it on the fly. Using a validator warning should work, though we use https://github.com/simonpoole/OpeningHoursParser and it should be added there.
comment:3 by , 3 months ago
Cc: | added |
---|
Please also see full discussion at https://community.openstreetmap.org/t/automated-edit-proposal-convert-non-standard-dashes-to-standard-dashes/110206/