@gen.coroutine
def ListIdentities(client, obj_store, user_id, device_id, request):
  """Returns a list of identities linked to this account."""
  def _MakeIdentityDict(ident):
    i_dict = {'identity': ident.key}
    if ident.authority is not None:
      i_dict['authority'] = ident.authority
    return i_dict

  query_expr = user_id % 'identity.user_id=%d'
  identities = yield gen.Task(Identity.IndexQuery, client, query_expr, ['key', 'authority'])

  raise gen.Return({'identities': [_MakeIdentityDict(ident) for ident in identities]})
dataset/ETHPy150Open viewfinderco/viewfinder/backend/www/service.py/ListIdentities/swapped operands of `%`