def get_targets(date):
    return models.FileVersion.find(
        Q('date_created', 'lt', date - DELTA_DATE) &
        Q('status', 'ne', 'cached') &
        Q('metadata.archive', 'exists', True) &
        Q('location', 'ne', None)
    )
dataset/ETHPy150Open CenterForOpenScience/osf.io/scripts/osfstorage/glacier_audit.py/get_targets/original