torchbox / torchbox/django-pattern-library
render_patterns should continue execution when a template fails to render
Open
@thibaudcolas is already working on this.
Since Dec 11, 2020.
django
enhancement
- Dominant language
- Python
- Stars
- 423
- Forks
- 53
- PR merge metrics
- No merged PRs in 30d
Description
Is your proposal related to a problem?
In its current instance, the render_patterns command stops execution as soon as a template fails to render.
Describe the solution you'd like
While this might be suitable as a basic check, it would be better for it to keep processing other patterns, displaying errors along the way, and then returning with an error status code.
At the same time it would be nice to consider whether:
- The current "fail fast" behavior should be kept under a flag or not (it’s a common feature of test runners, but I’m unsure of its usefulness here)
- Whether there should be a way to ignore failures in specific patterns, or provide input to the command so only specific patterns are processed (allowlist/blocklist or similar). While at first I didn’t think this would be useful, it would probably help adopting the command.
Describe alternatives you've considered
Fix all patterns 😬
Additional context
This would also be a good occasion to review the output of the command to check whether it’s suitable or not.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.