Power validation rules update
— at Version 9
Hi,
Due to recently power presets update, this ticket aims to provide updated guidelines regarding the validation of user inputs with these keys.
This comes after some objects have been broken by non-knowledgable users (substation on open poly-line, power terminal in the middle of a power way and so on...)
Here are the valid features associated with the main power keys, got from the up to date wiki
Tag (wiki) | Valid features | Preset | object type validator rule
|
---|
Tag:power=plant | area, relation | ✔ | ✔
|
Tag:power=generator | node, area | ✔ | not needed
|
Tag:power=cable | way | ✔ | not needed
|
Tag:power=line | way | ✔ | ✔ Done.
|
Tag:power=minor_line | way | ✔ | not needed
|
Tag:power=tower | node | ✔ | ✔ Done.(for unclosed ways only)
|
Tag:power=pole | node | ✔ | ✔
|
Tag:power=terminal | node | Not in Preset, see #12297 | -
|
Tag:power=portal | node, way | ✔ | not needed
|
Tag:power=insulator | node, way | ✔ | not needed
|
Tag:power=catenary_mast | node | Not in Preset, see #12297 | -
|
Tag:power=transformer | node | Used 8944 times on ways. Keep preset as is | not needed
|
Tag:power=switch or Tag:power=pole+switch=yes or Tag:power=tower+switch=yes | node | ✔ | not needed
|
Tag:power=substation | node, area | ✔ | not needed (area style not closed warning for unclosed ways already there)
|
Tag:power=converter | node, area | ✔ | not needed (area style not closed warning for unclosed ways already there)
|
Tag:power=compensator | node, area | ✔ | not needed (area style not closed warning for unclosed ways already there)
|
Tag:power=insulator | node, way | ✔ Done. | not needed
|
Tag:building=transformer_tower | node, area | ✔ | not needed (area style not closed warning for unclosed ways already there)
|
Presets may be updated according to this table and I suggest to prompt a validation warning when such keys are used on different features than the given ones.
It may be great to update current validation rules :
And add a few more :
Rule | Description | Progress
|
---|
A Tag:power=cable without Key:location | A power cable is a feature which must be set in a dedicated location such as indoor, underground or undersea (non exhaustive list). Any power cable object without the location key may show up a validation warning. | Wiki says that location=* is optional and that underground is the assumed default value for power=cable. However 5290 out of 7963 cables have the location tag. So add this as info level.
|
Crossing between road, railroad, path, landuse, waterways and power ways | Power lines may be long objects crossing through country and mappers can easily place nodes in common with roads or landuse areas. A validation error should be prompted to reduce the amount of such problems. |
|
These lists can be improved according to the experience of contributors and developers
Change History
(9)
Description: |
modified (diff)
|
Description: |
modified (diff)
|
Description: |
modified (diff)
|
Description: |
modified (diff)
|
Component: |
Core → Core validator
|
Description: |
modified (diff)
|
In 9494/josm: