def METHOD_NAME(self, request, queryset):
    """Cancel a subscription."""
    for subscription in queryset:
        try:
            instance = subscription.cancel()
            messages.success(request, f"Successfully Canceled: {instance}")
        except stripe.error.InvalidRequestError as error:
            messages.warning(request, error)