Skip to content

Also query name.* fields when street is present #142

@fcruzel

Description

@fcruzel

Bug description

Right now Pelias only queries address_parts.* fields (e.g., address_parts.street, address_parts.number) when a street is present, and completely omits name.* phrase queries in those scenarios. This is missing results, since for example importing alternative names (think name_json though csv-importer) gets put into the name.default route, and that is not searched in the instances where street is detected in the input.

Steps to reproduce

  • Make sure to enable libpostal
  • Search an address that libpostal is able to detect a street within. E.g.: "ZULOAGA 1 SAN BARTOLOME DE TIRAJANA", gets parsed as
    "parser": "libpostal",
    "parsed_text": {
        "street": "zuloaga",
        "housenumber": "1",
        "city": "san bartolome de tirajana"
    }
  • This should be enough for Pelias to only search in address_parts, ignoring name.* routes.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions