Bug : Relative path in extends and include does not work when using template_file (#976)

Co-authored-by: Juro Oravec <juraj.oravec.josefson@gmail.com>
This commit is contained in:
lilian D 2025-02-16 13:29:37 +01:00 committed by GitHub
parent 3cf586a974
commit 58d4c78671
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 64 additions and 1 deletions

View file

@ -737,7 +737,10 @@ class Component(
template: Template = cached_template(
template_string=template_body,
name=self.template_file or self.name,
origin=Origin(name=self.template_file or get_import_path(self.__class__)),
origin=Origin(
name=self.template_file or get_import_path(self.__class__),
template_name=self.template_file or self.name,
),
)
else:
template = template_body