def renew_service(request, pk):
    """
        renew an existing service
        :param request object
        :param pk: the primary key of the service to renew
        :type pk: int
    """
    default_provider.load_services()
    service = get_object_or_404(ServicesActivated, pk=pk)
    service_name = str(service.name)
    service_object = default_provider.get_service(service_name)
    lets_auth = getattr(service_object, 'auth')
    getattr(service_object, 'reset_failed')(pk=pk)
    return redirect(lets_auth(request))
def renew_service ( request , pk ) : default_provider . load_services ( ) service = get_object_or_404 ( ServicesActivated , pk = pk ) service_name = str ( service . name ) service_object = default_provider . get_service ( service_name ) lets_auth = getattr ( service_object , 'auth' ) getattr ( service_object , 'reset_failed' ) ( pk = pk ) return redirect ( lets_auth ( request ) )
renew an existing service
        :param request object
        :param pk: the primary key of the service to renew
        :type pk: int