'Execute this task locally, by blocking until the task returns.
Arguments:
args (Tuple): positional arguments passed on to the task.
kwargs (Dict): keyword arguments passed on to the task.
throw (bool): Re-raise task exceptions.
Defaults to the :setting:`task_eager_propagates` setting.
Returns:
celery.result.EagerResult: pre-evaluated result.'

def apply(self, args=None, kwargs=None, link=None, link_error=None, task_id=None, retries=None, throw=None, logfile=None, loglevel=None, headers=None, **options):

    from celery.app.trace import build_tracer
    app = self._get_app()
    args = (args or ())
    if (self.__self__ is not None):
        args = ((self.__self__,) + tuple(args))
    kwargs = (kwargs or {})
    task_id = (task_id or uuid())
    retries = (retries or 0)
    if (throw is None):
        throw = app.conf.task_eager_propagates
    task = app._tasks[self.name]
    request = {u'id': task_id, u'retries': retries, u'is_eager': True, u'logfile': logfile, u'loglevel': (loglevel or 0), u'hostname': gethostname(), u'callbacks': maybe_list(link), u'errbacks': maybe_list(link_error), u'headers': headers, u'delivery_info': {u'is_eager': True}}
    tb = None
    tracer = build_tracer(task.name, task, eager=True, propagate=throw, app=self._get_app())
    ret = tracer(task_id, args, kwargs, request)
    retval = ret.retval
    if isinstance(retval, ExceptionInfo):
        (retval, tb) = (retval.exception, retval.traceback)
    state = (states.SUCCESS if (ret.info is None) else ret.info.state)
    return EagerResult(task_id, retval, state, traceback=tb)
