steal/port jinja2's debug.py exception rewriting logic
还没有人认领这个 Issue。
评估
调研方向
从 mako-render 脚本及其 main() 入口点开始,然后将当前的错误处理与 issue 中要求的行为以及 Jinja2 在 debug.py 中的异常重写逻辑进行比较。当渲染非 HTML 输出时,模板错误能够生成可用的 traceback(包括通过建议的 stderr 路径)即表示完成。
由索引模型根据 Issue 内容生成。
描述
Migrated issue, originally created by Anonymous
The mako-render render script is useful for rendering templates in a non-html environment (eg I use it to generate c++ code ...)
It currently doesn't produce usable tracebacks when there is an error in the template. It should do something like
try:
print render(data)
except:
from mako import exceptions
from sys import stderr
print >> sys.stderr, exceptions.text_error_template().render()
in main()
- 主要语言
- Python
- 星标
- 461
- 派生
- 104
- PR 合并指标
- 30 天内没有已合并 PR
环境准备
- 没有 Dockerfile 或 Docker Compose 文件
- 有 Pull Request 模板
- 阅读贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
sqlalchemy/mako 的其他 Issue
-
难度 2/5 1-3 小时 新手友好度 72/100
sqlalchemy/mako#442 ·
-
难度 4/5 3-5 天 新手友好度 38/100
sqlalchemy/mako#432 · 1 条评论 ·
-
难度 4/5 3-5 天 新手友好度 35/100
sqlalchemy/mako#417 · 1 条评论 ·
-
难度 5/5 一周以上 新手友好度 30/100
sqlalchemy/mako#392 · 2 条评论 ·
-
难度 5/5 一周以上 新手友好度 15/100
sqlalchemy/mako#382 · 2 条评论 ·
相似的 Issue
-
type-bug
难度 2/5 1-3 小时 新手友好度 72/100
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 78/100
维护者通常 1 天内回复
-
push_gh-pages fails on master branch on forks可能已有人在做 关联的 PR 仍在进行中或已合并。 未关闭good first issue infrastructure
难度 2/5 1-3 小时 新手友好度 76/100
kuznia-rdzeni/coreblocks#1135 ·
-
good first issue server
难度 2/5 1-3 小时 新手友好度 85/100
维护者通常 1 天内回复
-
documentation priority: high
难度 2/5 1-3 小时 新手友好度 78/100
a-lex-s/mealie-telegram-bot#54 ·
维护者通常 1 天内回复