pelias / docker

Run the Pelias geocoder in docker containers, including example projects.
MIT License
314 stars 217 forks source link

PeliasModelError: invalid regex test, https://yavuzgallery.com should not match /https?:\/\// #329

Closed vctqs1 closed 7 months ago

vctqs1 commented 7 months ago

Describe the bug

error: [openstreetmap] tag_mapper error
error: [openstreetmap] PeliasModelError: invalid regex test, https://mustsharenews.com/changi-airport-taxiway-bridge should not match /https?:\/\//
    at Object.nomatch (/code/pelias/openstreetmap/node_modules/pelias-model/util/valid.js:117:13)
    at Document.setNameAlias (/code/pelias/openstreetmap/node_modules/pelias-model/Document.js:263:18)
    at /code/pelias/openstreetmap/stream/tag_mapper.js:53:19
    at /code/pelias/openstreetmap/node_modules/lodash/lodash.js:4967:15
    at baseForOwn (/code/pelias/openstreetmap/node_modules/lodash/lodash.js:3032:24)
    at /code/pelias/openstreetmap/node_modules/lodash/lodash.js:4936:18
    at Function.forEach (/code/pelias/openstreetmap/node_modules/lodash/lodash.js:9410:14)
    at DestroyableTransform._transform (/code/pelias/openstreetmap/stream/tag_mapper.js:34:9)
    at DestroyableTransform.Transform._read (/code/pelias/openstreetmap/node_modules/through2/node_modules/readable-stream/lib/_stream_transform.js:166:10)
    at DestroyableTransform.Readable.read (/code/pelias/openstreetmap/node_modules/through2/node_modules/readable-stream/lib/_stream_readable.js:428:10)
error: [openstreetmap] {
  "name": {},
  "parent": {},
  "address_parts": {},
  "center_point": {
    "lon": 103.981672,
    "lat": 1.341471
  },
  "category": [],
  "addendum": {},
  "source": "openstreetmap",
  "layer": "venue",
  "source_id": "way/1160231091",
  "bounding_box": "{\"min_lat\":1.34075,\"max_lat\":1.3419159,\"min_lon\":103.9807734,\"max_lon\":103.9835476}"
}

Steps to Reproduce Steps to reproduce the behavior:

  1. installing https://github.com/pelias/docker/tree/master/projects/singapore
  2. Run 'pelias import all'
  3. See error

Expected behavior Remove this error

Environment (please complete the following information):

Pastebin/Screenshots image

missinglink commented 7 months ago

These are just warnings, you can ignore them. It's triggered by a data error where there is a URL in one of the name fields of way/1160231091

missinglink commented 7 months ago

I've fixed the offending record in OSM https://www.openstreetmap.org/way/1160231091

Screenshot 2023-11-21 at 15 01 06