def METHOD_NAME(cls):
    now = timezone.now()
    subscriptions = Subscription.objects.filter(
        expires__range=(now - timedelta(days=10), now + timedelta(days=3)),
        enabled=True,
    ).exclude(payment=None)
    for subscription in subscriptions:
        # Is this repeating subscription?
        if not subscription.get_repeat():
            continue
        # Skip this in case there is another subscription, for example on service
        # upgrade on downgrade
        if subscription.could_be_obsolete():
            continue
        # Check recurring payment
        payment = subscription.payment_obj
        if not payment.recurring:
            subscription.send_notification("payment_expired")
            continue
        # Trigger recurring payment
        cls.peform_payment(
            payment,
            subscription.list_payments(),
            amount=subscription.package_obj.price,
        )