I have such SortExpression:
from google.appengine.api.search import search
search.SortExpression(expression = 'distance(geoLocation, geopoint(%s, %s))'
% (geoLatitude, geoLongitude),
direction = search.SortExpression.ASCENDING,
default_value = sys.float_info.max)
What should be default_value
for distance()
?
Currently sys.float_info.max
works on SDK but generates errors on production:
InvalidRequest: Failed to parse search request "tag:"zamówienia internetowe" AND tag:"zamówienia na teraz""; Default text value is not appropriate for sort expression 'distance(geoLocation, geopoint(52.1967225, 20.8892005))'