Changeset 7818 in josm


Ignore:
Timestamp:
2014-12-17T14:54:55+01:00 (5 years ago)
Author:
Klumbumbus
Message:

see #10837 - add some more validation rules (based on rules by naoliv)

Location:
trunk/data/validator
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/data/validator/combinations.mapcss

    r7767 r7818  
    134134}
    135135
     136/* {0.key} together with {1.key}, see #10837 */
     137*[noname?][name],
     138*[highway]["addr:street"] {
     139  throwWarning: tr("{0} together with {1}", "{0.key}", "{1.key}");
     140}
     141
    136142/* {0} on suspicious object */
    137143*[tunnel  ][!highway][!railway][!waterway][public_transport != platform][man_made != pipeline],
     
    165171}
    166172
    167 /* see ticket #9593 */
     173/* see #9593 */
    168174*[sport][tourism != hotel][highway != raceway][leisure !~ /^(sports_centre|stadium|track|pitch|golf_course|water_park|swimming_pool|recreation_ground)$/][natural !~ /^(beach|bare_rock)$/][amenity !~ /^(pub|restaurant|swimming_pool)$/][landuse !~ /^(recreation_ground|piste|farm|farmland)$/] {
    169175    throwWarning: tr("sport without physical feature");
     
    187193    throwWarning: tr("{0} should be on the node where {1} and {2} intersect", "ford", "highway", "waterway");
    188194}
     195
     196/* any other *_name tag but not a name, see #10837 */
     197*[/_name$/][!name] {
     198  throwWarning: tr("alternative name without {0}", "{1.key}");
     199}
     200
     201/* see #10837 */
     202way[destination][!oneway?] {
     203  throwWarning: tr("incomplete usage of {0} on a way without {1}", "{0.key}", "{1.key}");
     204  suggestAlternative: "destination:forward";
     205  suggestAlternative: "destination:backward";
     206}
  • trunk/data/validator/deprecated.mapcss

    r7737 r7818  
    330330}
    331331
    332 /* see #10661 */
    333 *[barrier=yes] {
     332/* see #10661, #10837 */
     333*[barrier=yes],
     334*[amenity=yes],
     335*[place=yes] {
    334336  throwWarning: tr("{0}={1} is unspecific. Please replace ''{1}'' by a specific value.", "{0.key}", "{0.value}");
    335337}
    336338
    337 /* see #10693 - http://wiki.openstreetmap.org/wiki/Proposed_features/drop_recommendation_for_place_name */
     339/* see #10693 - http://wiki.openstreetmap.org/wiki/Proposed_features/drop_recommendation_for_place_name , #10837 */
    338340*[place_name][!name] {
    339341  throwWarning: tr("{0} should be replaced with {1}", "{0.key}", "{1.key}");
    340342  fixChangeKey: "place_name => name";
     343}
     344*[place][place_name = *name] {
     345  throwWarning: tr("{0} = {1}; remove {0}", "{1.key}", "{1.value}");
     346  fixRemove: "{1.key}";
    341347}
    342348
     
    355361  fixAdd: "mooring=yes";
    356362}
     363
     364/* see #10837 */
     365*[building][levels] {
     366  throwWarning: tr("{0} is deprecated", "{1.key}");
     367  suggestAlternative: "building:levels";
     368  fixChangeKey: "levels => building:levels";
     369}
Note: See TracChangeset for help on using the changeset viewer.