import copy


def convert_results_to_list(results, deep_copy=True):
    """
    Given a Whoosh results object, converts it to a list and returns that list.
    Useful, as the Whoosh results object does not permit reassignment of Hit objects.
    Note that if deep_copy is True, a deep copy of the list is returned.
    """
    results_list = []
    
    for hit in results:
        if deep_copy:
            results_list.append(copy.copy(hit))
            continue
        
        results_list.append(hit)
    
    return results_list