Julian Simioni
204f5297de
Remove all leading newlines in files
7 years ago
Julian Simioni
02aac0c13e
Remove use stricts
7 years ago
Julian Simioni
8bccfc4fd2
Remove other instances of Mapzen
7 years ago
missinglink
e01fdb85c9
support aliases for label generation
7 years ago
missinglink
7a01e794cf
support aliases for name fields
7 years ago
Julian Simioni
e5e3b92af3
Fix extremely verbose, repeated error output
...
In some error cases, a warning is repeated many many times. It turns out
there is code checking against elasticsearch error codes, and warning
_each_ time it fails to match aganst one of them.
Many times, the error that is being compared is not from elasticsearch,
and in any case, the [elasticsearch-exceptions](https://www.npmjs.com/package/elasticsearch-exceptions )
module is 3 years old. We should rewrite most of this code and stop
using that module.
For now, this at least reduces log noise.
7 years ago
missinglink
1752875f11
feat: fix attribution link
7 years ago
Julian Simioni
5247ea575d
Give variable a better name
7 years ago
Julian Simioni
c966e6f6ae
Allow the minimum Elasticearch query size to be set per endpoint
...
Reverse queries don't need as much deduping, for example
7 years ago
Julian Simioni
2e92f15a91
Whitespace
7 years ago
antoine-de
3489517da3
dedup osm/OA address
...
linked to https://github.com/pelias/pelias/issues/541
and maybe to https://github.com/pelias/pelias/issues/541 but I cannot
reproduce it.
and to the fact that there are lots of dupplicates in france like:
[20 rue hector malot
paris](https://mapzen.com/search/explorer/?query=search&text=20%20rue%20hector%20malot%20paris )
that returns 1 result from open address and 1 result from OSM
now we first check which source has a zipcode and if both have, we
prefer OA over OSM
7 years ago
Diana Shkolnikov
cb59e305b0
log number of streets to be interpolated
7 years ago
Stephen Hess
16e01b5049
remove unused require
7 years ago
Stephen Hess
759c0e0939
switched to lodash.extend over extend module
7 years ago
Stephen Hess
05da79923f
wrap interpolation service call to intercept errors
7 years ago
Diana Shkolnikov
40870c4e04
check for missing parent object in confidence score computation
7 years ago
Diana Shkolnikov
b60e0113b3
check for missing parent object in confidence score computation
7 years ago
Julian Simioni
a233e11d59
Remove Access-Control-Allow-Credentials header
...
This header is only relevant if dealing with authentication via cookies
or other methods in HTTP requests. The Pelias API intentionally doesn't
deal with authentication at all, assuming anyone who wants
authentication will deal with it using a service placed between Pelias
and end users.
Additionally the CORS spec [does not allow](https://developer.mozilla.org/en-US/docs/Web/HTTP/Access_control_CORS#Credentialed_requests_and_wildcards )
specifying this header while setting a wildcard for
`Access-Control-Allow-Origin`, so it can cause problems in some cases.
Fixes https://github.com/pelias/api/issues/971
7 years ago
Adam Rousell
f86ee4a40f
Added postalcode rules for node-postal call and fallbacks
7 years ago
Stephen Hess
bfa8475443
fix @missinglink's typo
7 years ago
Stephen Hess
cf167ce933
map sources from helper/type_mapping.js
7 years ago
Stephen Hess
41831ab7a0
converted middleware/interpolate to use injected service
7 years ago
Stephen Hess
92d18af886
updated changeLanguage to injection model
7 years ago
Lily He
cafb7d9277
created new debug helper class and debug sanitizer
7 years ago
Stephen Hess
2e90892b25
info->debug to reduce log noise
7 years ago
Stephen Hess
775fd1f568
updated code+tests to findById name array output format
7 years ago
Stephen Hess
5a8ddd6268
added debug logging for sorting
8 years ago
Stephen Hess
238b49a0d8
added should_execute to sortResponseData
8 years ago
Stephen Hess
446d428292
don't reassign, sort works inline
8 years ago
Stephen Hess
5d7a467909
added response data sorting middleware
8 years ago
Stephen Hess
8429e0f22a
added response data sorting middleware
8 years ago
Diana Shkolnikov
a3e8f8d566
fix exception when no ids are found in placetype
8 years ago
Diana Shkolnikov
6cc53e4e0b
merge multiple hierarchies into arrays and use first ones
8 years ago
Kevin Ennis
512cec9945
Prefer openaddresses results with zip code
8 years ago
Julian Simioni
6b0b124d8f
Always query for a minimum of 20 results from Elasticsearch
...
Fallback and interpolation queries rely on several results coming back
from Elasticsearch to ensure the best result is returned. It was
possible that queries with `size=1` would not return enough results from
Elasticsearch. This change ensures even with `size=1` a sufficient
number of results are returned.
Fixes https://github.com/pelias/pelias/issues/562
8 years ago
Diana Shkolnikov
798363da1e
remove unwanted log statement
8 years ago
Diana Shkolnikov
e1eeb25776
fix: geonames ids should not be misrepresented in hiearchy
8 years ago
Diana Shkolnikov
e46c17a84a
Sort interpolated results to show address first
8 years ago
missinglink
8d774ab6d3
language service
8 years ago
Peter Johnson
6fcc0f6826
language: logging
8 years ago
Peter Johnson
43131248b7
language: fallback scenario from invalid querystring to valid header
8 years ago
Peter Johnson
39b1367778
language: accept param as well as request headers
8 years ago
missinglink
ae2c0e7671
negotiate HTTP locales for incoming browser requests
8 years ago
Diana Shkolnikov
6dd4cc9bd8
fix postalcodes not showing up in results
8 years ago
Diana Shkolnikov
a52691c61e
feat: search by postalcode
8 years ago
missinglink
3a4d26077a
interpolation: fix: source_id mapping
8 years ago
Peter Johnson
69be6e062a
service: interpolation: tests
8 years ago
Peter Johnson
576d1a1809
interpolation: integration v1
8 years ago
Diana Shkolnikov
30590a41d3
fix: match_type and confidence score were not correct for certain queries
8 years ago
Peter Johnson
00fae29fad
update 500 middleware; add log statement, clean up code
8 years ago