-
Notifications
You must be signed in to change notification settings - Fork 25.6k
Description
Elasticsearch version (bin/elasticsearch --version): 5.6.3 (bug also appears to be on master)
Plugins installed: []
JVM version (java -version): 1.8.0_161
OS version (uname -a if on a Unix-like system): Darwin
Description of the problem including expected versus actual behavior:
When using a geo_polygon query using points, I would expect any lon value < -180 or > 180 to be invalid and return an error similar to the one returned when any lat value is < -90 or > 90. Looking at the code here the check does exist but is using the lat value instead of the lon value.
This also appears to exist in the current master version (link to code here)
Steps to reproduce:
You can reproduce by running a geo_polygon query using lat/long points in elasticsearch 5.6.3. Note that you will need a geo_point field to query against. Using a lat of < -90 or > 90 will return an error about an illegal latitude value, but using a lon of < -180 or > 180 will not return an error.
Based on the code link above, I would also assume you could do the same on any version > 5.6.3.