1 | # JOSM TagChecker validator file
|
---|
2 |
|
---|
3 | # Format:
|
---|
4 | # Each line specifies a certain error to be reported
|
---|
5 | # <data type> : messagetype : <key><expression><value>
|
---|
6 | # Lines starting with a # are considered as comments.
|
---|
7 | #
|
---|
8 | # Data type can be:
|
---|
9 | # node - a node point
|
---|
10 | # way - a way
|
---|
11 | # relation - a relation
|
---|
12 | # * - all data types
|
---|
13 | #
|
---|
14 | # Message type can be:
|
---|
15 | # E - an error
|
---|
16 | # W - a warning
|
---|
17 | # I - an low priority informational warning
|
---|
18 | #
|
---|
19 | # Key and value are expressions describing certain keys and values of these keys.
|
---|
20 | # Regulator expressions are supported. In this case the expressions starts and
|
---|
21 | # ends with a / sign. If an 'i' is appended, the regular expression is
|
---|
22 | # case insensitive. For instance, /foo|bar/i
|
---|
23 | #
|
---|
24 | # The * sign indicates any string.
|
---|
25 | # The texts BOOLEAN_TRUE and BOOLEAN_FALSE in the value part indicate a special
|
---|
26 | # handling for boolean values (yes, true, 0, false, no, ...).
|
---|
27 | #
|
---|
28 | # Expression can be:
|
---|
29 | # != - the key/value combination does not match
|
---|
30 | # == - the key/value combination does match
|
---|
31 | #
|
---|
32 | # To have more complicated expressions, multiple elements can be grouped together
|
---|
33 | # with an logical and (&&).
|
---|
34 | #
|
---|
35 | # The comment at the end of a rule is displayed in validator description
|
---|
36 | #
|
---|
37 | # Empty lines and space signs are ignored
|
---|
38 |
|
---|
39 | way : W : highway == * && name == /.* (Ave|Blvd|Cct|Cir|Cl|Cr|Crct|Cres|Crt|Ct|Dr|Drv|Esp|Espl|Hwy|Ln|Mw|Mwy|Pl|Rd|Qy|Qys|Sq|St|Str|Ter|Tce|Tr|Wy)\.?$/i # abbreviated street name
|
---|
40 |
|
---|
41 | node : W : oneway == * # oneway tag on a node
|
---|
42 | node : W : bridge == BOOLEAN_TRUE # bridge tag on a node
|
---|
43 | node : W : highway == tertiary # wrong highway tag on a node
|
---|
44 | node : W : highway == secondary # wrong highway tag on a node
|
---|
45 | node : W : highway == residential # wrong highway tag on a node
|
---|
46 | node : W : highway == unclassified # wrong highway tag on a node
|
---|
47 | node : W : highway == track # wrong highway tag on a node
|
---|
48 | way : I : highway == unclassified && name != * # Unnamed unclassified highway
|
---|
49 | way : I : highway == secondary && ref != * # highway without a reference
|
---|
50 | way : I : highway == tertiary && ref != * # highway without a reference
|
---|
51 | way : I : highway == motorway && nat_ref != * # highway without a reference
|
---|
52 | * : W : highway == road # temporary highway type
|
---|
53 | * : W : / *name */i == * && name != * # misspelled key name
|
---|
54 |
|
---|
55 | # The following could replace unnamed way check. Still at the moment we keep it as it is
|
---|
56 | #way : W : junction == roundabout && highway == /motorway|trunk|primary|secondary|tertiary|residential|pedestrian/ && /name|ref|(name:.*)|(.*_name)|(.*_ref)/ != * # Unnamed junction
|
---|
57 | #way : W : highway == /motorway|trunk|primary|secondary|tertiary|residential|pedestrian/ && /name|ref|(name:.*)|(.*_name)|(.*_ref)/ != * # Unnamed
|
---|
58 |
|
---|
59 | way : W : highway == cycleway && bicycle == BOOLEAN_FALSE # cycleway with tag bicycle
|
---|
60 | way : W : highway == footway && foot == BOOLEAN_FALSE # footway with tag foot
|
---|
61 | #way : I : highway == cycleway && bicycle == * # cycleway with tag bicycle
|
---|
62 | #way : I : highway == footway && foot == * # footway with tag foot
|
---|
63 | way : W : highway == cycleway && cycleway == lane # separate cycleway as lane on a cycleway
|
---|
64 | way : W : highway == * && barrier == * # barrier used on a way
|
---|
65 |
|
---|
66 | #way : I : waterway == * && layer != * # waterway without layer tag
|
---|
67 | way : I : highway == footway && maxspeed == * # maxspeed used for footway
|
---|
68 | way : I : highway == steps && maxspeed == * # maxspeed used for footway
|
---|
69 |
|
---|
70 | # see #5844, #6760
|
---|
71 | #way : W : oneway != BOOLEAN_FALSE && /.*:(backward|forward)/ == * # oneway combined with *:backward/forward
|
---|
72 |
|
---|
73 | * : W : layer == /\+.*/ # layer tag with + sign
|
---|
74 |
|
---|
75 | * : I : name == /.*Strasse.*/i # street name contains ss
|
---|
76 |
|
---|
77 | relation : E : type != * # relation without type
|
---|
78 |
|
---|
79 | node : I : amenity == /restaurant|cafe|fast_food/ && name != * # restaurant without name
|
---|
80 | #way : I : highway != * && railway != * && waterway != * && name == * # unusual named way type
|
---|
81 | #* : W : natural == water && waterway == * # unusual tag combination (natural=water & waterway)
|
---|
82 | * : W : highway == * && waterway == * # unusual tag combination (highway & waterway)
|
---|
83 | * : W : highway == * && natural == * # unusual tag combination (highway & natural)
|
---|
84 |
|
---|
85 | * : W : natural == water && leisure == swimming_pool # natural water used for swimming pool
|
---|
86 | * : W : natural == water && amenity == swimming_pool # natural water used for swimming pool
|
---|
87 |
|
---|
88 | # see ticket #5017
|
---|
89 | # Taginfo query: select keypairs.key1, keypairs.key2, keypairs.count_all, keys.count_all, cast(keypairs.count_all as real)/keys.count_all as from_fraction_all from keys, keypairs where key1='waterway' and keys.key=keypairs.key2 and (key1<>'highway' or keypairs.count_all>12000) and (key1<>'railway' or keypairs.count_all>3000) and (key1<>'waterway' or keypairs.count_all>800) and key2 not like '%:%' and from_fraction_all>0.97 and 1 union select keypairs.key2, keypairs.key1, keypairs.count_all, keys.count_all, cast(keypairs.count_all as real)/keys.count_all as from_fraction_all from keys, keypairs where key2='waterway' and keys.key=keypairs.key1 and (key2<>'highway' or keypairs.count_all>12000) and (key2<>'railway' or keypairs.count_all>3000) and (key2<>'waterway' or keypairs.count_all>800) and key1 not like '%:%' and from_fraction_all>0.97 and 1 order by keypairs.count_all desc limit 1000;
|
---|
90 | * : W : incline == * && highway != * # incline without highway
|
---|
91 | * : W : junction == * && highway != * # junction without highway
|
---|
92 | * : W : lanes == * && highway != * # lanes without highway
|
---|
93 | * : W : lcn == * && highway != * # lcn without highway
|
---|
94 | * : W : lit == * && highway != * && public_transport != platform # lit without highway
|
---|
95 | * : W : living_street == * && highway != * # living_street without highway
|
---|
96 | * : W : maintenance == * && highway != * # maintenance without highway
|
---|
97 | * : W : maxspeed == * && highway != * # maxspeed without highway
|
---|
98 | * : W : median == * && highway != * # median without highway
|
---|
99 | * : W : moped == * && highway != * # moped without highway
|
---|
100 | * : W : motor_vehicle == * && highway != * # motor_vehicle without highway
|
---|
101 | * : W : motorroad == * && highway != * # motorroad without highway
|
---|
102 | * : W : ntd_id == * && highway != * # ntd_id without highway
|
---|
103 | * : W : oneway == * && highway != * # oneway without highway
|
---|
104 | * : W : sac_scale == * && highway != * # sac_scale without highway
|
---|
105 | * : W : segregated == * && highway != * # segregated without highway
|
---|
106 | * : W : sidewalk == * && highway != * # sidewalk without highway
|
---|
107 | * : W : smoothness == * && highway != * # smoothness without highway
|
---|
108 | * : W : snowplowing == * && highway != * # snowplowing without highway
|
---|
109 | * : W : step_count == * && highway != * # step_count without highway
|
---|
110 | * : W : toll == * && highway != * # toll without highway
|
---|
111 | * : W : tracktype == * && highway != * # tracktype without highway
|
---|
112 | * : W : trail_visibility == * && highway != * # trail_visibility without highway
|
---|
113 | * : W : trolley_wire == * && highway != * # trolley_wire without highway
|
---|
114 | * : W : zip_left == * && highway != * # zip_left without highway
|
---|
115 | * : W : zip_right == * && highway != * # zip_right without highway
|
---|
116 | * : W : detail == * && railway != * # detail without railway
|
---|
117 | * : W : eddy_current_brake == * && railway != * # eddy_current_brake without railway
|
---|
118 | * : W : electrified == * && railway != * # electrified without railway
|
---|
119 | * : W : etcs == * && railway != * # etcs without railway
|
---|
120 | * : W : gauge == * && railway != * # gauge without railway
|
---|
121 | * : W : grade_of_track == * && railway != * # grade_of_track without railway
|
---|
122 | * : W : kursbuchstrecke == * && railway != * # kursbuchstrecke without railway
|
---|
123 | * : W : lzb == * && railway != * # lzb without railway
|
---|
124 | * : W : old_railway_operator == * && railway != * # old_railway_operator without railway
|
---|
125 | * : W : operating_procedure == * && railway != * # operating_procedure without railway
|
---|
126 | * : W : pzb == * && railway != * # pzb without railway
|
---|
127 | * : W : radio == * && railway != * # radio without railway
|
---|
128 | * : W : structure_gauge == * && railway != * # structure_gauge without railway
|
---|
129 | * : W : tilting_technology == * && railway != * # tilting_technologie without railway
|
---|
130 | * : W : track_class == * && railway != * # track_class without railway
|
---|
131 | * : W : tracks == * && railway != * # tracks without railway
|
---|
132 | * : W : traffic_mode == * && railway != * # traffic_mode without railway
|
---|
133 | * : W : usage == * && railway != * # usage without railway
|
---|
134 | * : W : workrules == * && railway != * # workrules without railway
|
---|
135 | * : W : stream == * && waterway != * # stream without waterway
|
---|
136 | * : W : intermittent == * && waterway != * # intermittent without waterway
|
---|
137 | * : W : boat == * && waterway != * # boat without waterway
|
---|
138 | * : W : length_unit == * && waterway != * # length_unit without waterway
|
---|
139 | * : W : llid == * && waterway != * # llid without waterway
|
---|
140 | * : W : canal == * && waterway != * # canal without waterway
|
---|
141 | * : W : have_riverbank == * && waterway != * # have_riverbank without waterway
|
---|
142 | * : W : tunnel == * && highway != * && railway != * && waterway != * # tunnel without highway/railway/waterway
|
---|
143 | * : W : bridge == * && highway != * && railway != * && waterway != * # bridge without highway/railway/waterway
|
---|
144 | * : W : width == * && highway != * && railway != * && waterway != * # width without highway/railway/waterway
|
---|
145 | * : W : psv == * && highway != * && railway != * && waterway != * # psv without highway/railway/waterway
|
---|