Skip to content

Default postprocessors on EsriWGS are too strict. #19

Description

@lliss

Be default, if doing a gazetteer style search, the defautl postprocessors filter out everything.

To test:

Set up and run a new geocoder with EsriWSG:

pq = PlaceQuery(query='the white house', country='US')
result = geocoder.geocode(pq)

You should get a few responses from the raw response:

[<White House (-77.036428, 38.897928) EsriWGS>, <The White House (-122.633387, 45.57894) EsriWGS>]

But they get filtered out in /services/base.py

except Exception as e:
            upstream_response_info.set_success(False)
            upstream_response_info.errors.append(format_exc())
            return [], upstream_response_info
        if len(candidates) > 0:
            for p in self._postprocessors: # apply universal candidate postprocessing
                candidates = p.process(candidates) # merge lists
        return candidates, upstream_response_info

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions