Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Minijinja2: Improve error reporting #2784

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

michaelmelanson
Copy link

This change improves the error reporting for Minijinja2 templates.

Currently, when errors occur in a Minijinja2 template, it usually gives an error message that only has a top-level explanation of the problem. When the issue comes from an included file or a layout, this error message does not include enough details to diagnose the problem when the problem.

With this change, it now prints details about the entire error chain returned, which acts as a stack trace to find the cause of the error.

It also adds the error message on 'template not found' errors.

@SergioBenitez SergioBenitez force-pushed the minijinja-improved-error-reporting branch from a956454 to ee78062 Compare May 2, 2024 09:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant