def __call__(self, name, from_template=None, default_inherit=None): if base_config().template_dir: template_file = os.path.join(base_config().template_dir, name) else: template_file = pkg_resources.resource_filename(module_name, location + '/' + name) return Template.from_filename(template_file, namespace=namespace, default_inherit=default_inherit, get_template=self)
def __call__(self, name, from_template=None, default_inherit=None): template_file = pkg_resources.resource_filename( module_name, location + '/' + name) return Template.from_filename(template_file, namespace=namespace, default_inherit=default_inherit, get_template=self)
def __call__(self, name, from_template=None, default_inherit=None): if base_config().template_dir: template_file = os.path.join(base_config().template_dir, name) else: template_file = pkg_resources.resource_filename(module_name, location + '/' + name) return Template.from_filename(template_file, namespace=namespace, encoding='utf-8', default_inherit=default_inherit, get_template=self)
def __call__(self, name, from_template=None, default_inherit=None): return Template.from_filename(os.path.join(template_dir, name), namespace=namespace, default_inherit=default_inherit, get_template=self)