<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def get_accepted_features(features, proposed_feature):
 """Deselect candidate features from list of all features Args: features (List[Feature]):
 collection of all features in the ballet project: both accepted features and candidate ones that have not been accepted proposed_feature (Feature):
 candidate feature that has not been accepted Returns: List[Feature]: list of features with the proposed feature not in it. Raises: ballet.exc.BalletError: Could not deselect exactly the proposed feature. """

    def eq(feature):
        """Features are equal if they have the same source

        At least in this implementation...
        """
        return feature.source == proposed_feature.source

    # deselect features that match the proposed feature
    result = lfilter(complement(eq), features)

    if len(features) - len(result) == 1:
        return result
    elif len(result) == len(features):
        raise BalletError(
            'Did not find match for proposed feature within \'contrib\'')
    else:
        raise BalletError(
            'Unexpected condition (n_features={}, n_result={})'
            .format(len(features), len(result)))