Changes between Version 24 and Version 25 of Rules/PublicTransportGtfs
- Timestamp:
- 2020-08-31T14:34:07+02:00 (6 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Rules/PublicTransportGtfs
v24 v25 28 28 * [osmwiki:Proposed_features/Key:gtfs:trip_id gtfs:trip_id] 29 29 * [osmwiki:Proposed_features/Key:gtfs:trip_id:sample gtfs:trip_id:sample] 30 * [osmwiki:Proposed_features/Key:gtfs:source_date gtfs:source_date] 30 * ~~[osmwiki:Proposed_features/Key:gtfs:source_date gtfs:source_date]~~ replace by `gtfs:release_date` 31 * [osmwiki:Proposed_features/Key:gtfs:release_date gtfs:release_date] 31 32 * [osmwiki:Key:gtfs:stop_id gtfs:stop_id] 32 33 * [osmwiki:Key:interval interval] … … 226 227 /* One of many {0.key} but no {1.key} */ 227 228 228 /* gtfs: source_date */229 *[/(^gtfs:|:gtfs|^ref:IFOPT)/][!gtfs: source_date] {229 /* gtfs:release_date */ 230 *[/(^gtfs:|:gtfs|^ref:IFOPT)/][!gtfs:release_date] { 230 231 throwWarning: tr("GTFS tag without `{0}*`.", "{1.tag}"); 231 232 group: tr("Public Transport GTFS: missing tag"); … … 233 234 assertMatch: "node note:gtfs=A"; 234 235 assertMatch: "node ref:IFOPT=1"; 235 assertNoMatch: "node ref:IFOPT=1 gtfs: source_date=2019";236 assertNoMatch: "node ref:IFOPT=1 gtfs:release_date=2019"; 236 237 } 237 238 … … 264 265 assertNoMatch: "relation gtfs:trip_id=2.TA.90-742-B-j20-1.4.R"; 265 266 } 266 /* gtfs:feed, *:guid, gtfs: source_date */267 /* gtfs:feed, *:guid, gtfs:release_date */ 267 268 /* FIXME: Get proper list of valid values. */ 268 269 /* FIXME: Get proper syntax as regex displayed. */ … … 270 271 *[network:guid ][network:guid !~ /^(([A-Z]{2}-){2}[a-zA-Z]{2}.*|[A-Z]{2}-Flixbus|BO-C-Cochabamba|(CH|LU)-[a-zA-Z]{3,}|CO-BOY-[A-Z].+|ES-AR-Z-[A-Z].+|FR-IDF-(r|[a-zA-Z]{3,}.*)|MG-T-Antananarivo)$/], 271 272 *[operator:guid][operator:guid !~ /^(([A-Z]{2}-){2}[a-zA-Z]{2}.*|[A-Z]{2}-Flixbus|BO-C-Cochabamba|(CH|LU)-[a-zA-Z]{3,}|CO-BOY-[A-Z].+|ES-AR-Z-[A-Z].+|FR-IDF-(r|[a-zA-Z]{3,}.*)|MG-T-Antananarivo)$/], 272 *[gtfs: source_date][gtfs:source_date !~ /^20(1[7-9]|20)-(0[1-9]|1[0-2])-(3[01]|[12][0-9]|0[1-9])$/] {273 *[gtfs:release_date][gtfs:release_date !~ /^20(1[7-9]|20)-(0[1-9]|1[0-2])-(3[01]|[12][0-9]|0[1-9])$/] { 273 274 throwError: tr("Value `{0}` for `{1}=*` does not match value syntax.", "{0.value}", "{0.key}"); 274 275 /* throwError: tr("Value `{0}` for `{1}=*` does not match value syntax `{2}`.", "{0.value}", "{0.key}", "{1.value}"); */ … … 280 281 assertNoMatch: "relation gtfs:feed=AU-SA-Adelaide-Metro"; 281 282 assertNoMatch: "relation gtfs:feed=DE-SL-saarVV"; 282 assertMatch: "relation gtfs: source_date=2016-09-30";283 assertMatch: "relation gtfs: source_date=2020-9-3";284 assertMatch: "relation gtfs: source_date=2016-09-30";285 assertNoMatch: "relation gtfs: source_date=2020-09-30";283 assertMatch: "relation gtfs:release_date=2016-09-30"; 284 assertMatch: "relation gtfs:release_date=2020-9-3"; 285 assertMatch: "relation gtfs:release_date=2016-09-30"; 286 assertNoMatch: "relation gtfs:release_date=2020-09-30"; 286 287 } 287 288 /* ref:IFOPT, gtfs:stop_id */ … … 393 394 *[website =~ /^.*ptna\.openstreetmap\.de\/gtfs.+$/][website !~ /^.*network=([a-zA-Z]+[-]){2,}\d{4}(-\d\d){2}.*$/], 394 395 *[source =~ /^.*ptna\.openstreetmap\.de\/gtfs.+$/][source !~ /^.*network=([a-zA-Z]+[-]){2,}\d{4}(-\d\d){2}.*$/] { 395 throwWarning: tr("Relative GTFS url in `{0}=*`. Add the ` source_date` behind the network value with a minus `-` as separator.", "{0.key}");396 throwWarning: tr("Relative GTFS url in `{0}=*`. Add the `release_date` behind the network value with a minus `-` as separator.", "{0.key}"); 396 397 assertMatch: "node source=\"https://ptna.openstreetmap.de/gtfs/19\""; 397 398 assertNoMatch: "node source=\"https://ptna.openstreetmap.de/gtfs/DE/trips.php?network=DE-BW-VAG-2020-07-28&route_id=10-10-I-j20-1\"";
