async def async_render_will_timeout(self, timeout: float, variables: TemplateVarsType=None, strict: bool=False, **kwargs: Any) -> bool:
    'Check to see if rendering a template will timeout during render.\n\n        This is intended to check for expensive templates\n        that will make the system unstable.  The template\n        is rendered in the executor to ensure it does not\n        tie up the event loop.\n\n        This function is not a security control and is only\n        intended to be used as a safety check when testing\n        templates.\n\n        This method must be run in the event loop.\n        '
    if self.is_static:
        return False
    compiled = (self._compiled or self._ensure_compiled(strict=strict))
    if (variables is not None):
        kwargs.update(variables)
    self._exc_info = None
    finish_event = asyncio.Event()

    def _render_template() -> None:
        try:
            _render_with_context(self.template, compiled, **kwargs)
        except TimeoutError:
            pass
        except Exception:
            self._exc_info = sys.exc_info()
        finally:
            run_callback_threadsafe(self.hass.loop, finish_event.set)
    try:
        template_render_thread = ThreadWithException(target=_render_template)
        template_render_thread.start()
        (await asyncio.wait_for(finish_event.wait(), timeout=timeout))
        if self._exc_info:
            raise TemplateError(self._exc_info[1].with_traceback(self._exc_info[2]))
    except asyncio.TimeoutError:
        template_render_thread.raise_exc(TimeoutError)
        return True
    finally:
        template_render_thread.join()
    return False
Check to see if rendering a template will timeout during render.

This is intended to check for expensive templates
that will make the system unstable.  The template
is rendered in the executor to ensure it does not
tie up the event loop.

This function is not a security control and is only
intended to be used as a safety check when testing
templates.

This method must be run in the event loop.
async def async_render_will_timeout(self, timeout: float, variables: TemplateVarsType=None, strict: bool=False, **kwargs: Any) -> bool:
    'Check to see if rendering a template will timeout during render.\n\n        This is intended to check for expensive templates\n        that will make the system unstable.  The template\n        is rendered in the executor to ensure it does not\n        tie up the event loop.\n\n        This function is not a security control and is only\n        intended to be used as a safety check when testing\n        templates.\n\n        This method must be run in the event loop.\n        '
    if self.is_static:
        return False
    compiled = (self._compiled or self._ensure_compiled(strict=strict))
    if (variables is not None):
        kwargs.update(variables)
    self._exc_info = None
    finish_event = asyncio.Event()

    def _render_template() -> None:
        try:
            _render_with_context(self.template, compiled, **kwargs)
        except TimeoutError:
            pass
        except Exception:
            self._exc_info = sys.exc_info()
        finally:
            run_callback_threadsafe(self.hass.loop, finish_event.set)
    try:
        template_render_thread = ThreadWithException(target=_render_template)
        template_render_thread.start()
        (await asyncio.wait_for(finish_event.wait(), timeout=timeout))
        if self._exc_info:
            raise TemplateError(self._exc_info[1].with_traceback(self._exc_info[2]))
    except asyncio.TimeoutError:
        template_render_thread.raise_exc(TimeoutError)
        return True
    finally:
        template_render_thread.join()
    return False