def __init__(self, template, hass=None):
    'Instantiate a template.'
    if (not isinstance(template, str)):
        raise TypeError('Expected template to be a string')
    self.template: str = template.strip()
    self._compiled_code = None
    self._compiled: (jinja2.Template | None) = None
    self.hass = hass
    self.is_static = (not is_template_string(template))
    self._exc_info = None
    self._limited = None
    self._strict = None
Instantiate a template.
def __init__(self, template, hass=None):
    
    if (not isinstance(template, str)):
        raise TypeError('Expected template to be a string')
    self.template: str = template.strip()
    self._compiled_code = None
    self._compiled: (jinja2.Template | None) = None
    self.hass = hass
    self.is_static = (not is_template_string(template))
    self._exc_info = None
    self._limited = None
    self._strict = None