Markdown "safe" feature unclear
the behaviour of markdown is weird when using the "safe" option :
using markdown 1.6.2 rc-2
when markdown is used with defaults, html in the original text is not escaped, while when passed the "safe" option, it is escaped.
I haven't checked whether the problem exists with other versions of markdown, but with 1.6.2 the following (from contrib/markup/templatetags/markup.py) should be used instead
if hasattr(markdown, 'version'):
extensions = [e for e in arg.split(",") if e]
if len(extensions) > 0 and extensions[0] == "safe":
extensions = extensions[1:]
safe_mode = False
else:
safe_mode = True
Change History
(6)
Triage Stage: |
Unreviewed → Accepted
|
Component: |
Contrib apps → contrib.markup
|
Severity: |
→ Normal
|
Type: |
→ Bug
|
Resolution: |
→ wontfix
|
Status: |
new → closed
|
Change UI/UX from NULL to False.