(domain, location_ids)
Creates a generator for iterating through the user ids of the all the users in the
    given domain whose primary location is given in the list of location_ids.
Creates a generator for iterating through the user ids of the all the users in the
    given domain whose primary location is given in the list of location_ids.
Creates a generator for iterating through the user ids of the all the users in the given domain whose primary location is given in the list of location_ids .
def generate_user_ids_from_primary_location_ids(domain, location_ids):
    """
    Creates a generator for iterating through the user ids of the all the users in the
    given domain whose primary location is given in the list of location_ids.
    """
    for location_ids_chunk in chunked(location_ids, 50):
        for user_id in get_user_ids_from_primary_location_ids(domain, location_ids_chunk).keys():
            yield user_id
def generate_user_ids_from_primary_location_ids ( domain , location_ids ) : for location_ids_chunk in chunked ( location_ids , 50 ) : for user_id in get_user_ids_from_primary_location_ids ( domain , location_ids_chunk ) . keys ( ) : yield user_id