hmarr/mongoengine — Issue #343: can't have 2 special fields
Author: maxcountryman
Created: 2011-10-29 00:46:34+00:00
State: open

I'm getting an error when trying to filter a query by two GeoPointFields as Ride.objects(Q(orig__within_distance=orig_point_and_dist) & Q(dest__within_distance=dest_point_and_dist)). This is related to my previous issue but now the issue is either related directly to pymongo or the way pymongo is being interfaced.

Here's the error:

OperationFailure: command SON([('count', u'ride'), ('query', {'dest': {'$within': {'$center': [[47.6062095, -122.3320708], 0.5]}}, '_types': 'Ride', 'orig': {'$within': {'$center': [[47.6587802, -117.4260466], 0.5]}}}), ('fields', None)]) failed: exception: can't have 2 special fields