(
self,
environment: "Environment",
name: str,
globals: t.Optional[t.MutableMapping[str, t.Any]] = None,
)
| 512 | |
| 513 | @internalcode |
| 514 | def load( |
| 515 | self, |
| 516 | environment: "Environment", |
| 517 | name: str, |
| 518 | globals: t.Optional[t.MutableMapping[str, t.Any]] = None, |
| 519 | ) -> "Template": |
| 520 | loader, local_name = self.get_loader(name) |
| 521 | try: |
| 522 | return loader.load(environment, local_name, globals) |
| 523 | except TemplateNotFound as e: |
| 524 | # re-raise the exception with the correct filename here. |
| 525 | # (the one that includes the prefix) |
| 526 | raise TemplateNotFound(name) from e |
| 527 | |
| 528 | def list_templates(self) -> t.List[str]: |
| 529 | result = [] |
nothing calls this directly
no test coverage detected