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

Switch from Misaka to Python-Markdown #261

Open
fluffy-critter opened this issue Jul 29, 2019 · 1 comment
Open

Switch from Misaka to Python-Markdown #261

fluffy-critter opened this issue Jul 29, 2019 · 1 comment
Labels
large This is going to take a lot longer than most things markdown Functionality involving the Markdown processor
Milestone

Comments

@fluffy-critter
Copy link
Collaborator

Context

Misaka is built on Hoedown, which is apparently abandoned, and has led to too much hacking on the Publ side anyway. Python-Markdown is much more modular and up-to-date, and is probably a better choice of Markdown engine. It also allows local customizations in a less-hacky way than the Misaka shoehornings, and being pure Python it also means one less thing that requires a C++ compiler on Windows builds.

In order to make this change, there's a lot of stuff that will have to happen:

  • Ensure that the image spec parsing is close enough (in particular, supporting multiline expressions with spaces in them and the other "extensions" we use for image sets) — this is likely the hard part
  • Same for link spec parsing
  • Ensure that MathJax can still work, ideally with minimal change to the Markdown text
  • Stop calling pygments ourselves, as Python-Markdown's built-in code-hilite module does that for us
  • Probably a bunch of other non-obvious stuff

Also, I recall having evaluated Python-Markdown at some point and decided there was some reason I preferred Misaka at the time. Hopefully the issue I ran into is not actually an issue.

@fluffy-critter fluffy-critter added the large This is going to take a lot longer than most things label Jul 29, 2019
@fluffy-critter fluffy-critter added this to the low priority milestone Aug 4, 2019
@fluffy-critter fluffy-critter added the markdown Functionality involving the Markdown processor label Aug 9, 2019
@fluffy-critter
Copy link
Collaborator Author

Looks like Misaka has been working on moving off of Hoedown. Hopefully this will fix the Hoedown-specific issues without breaking the parts of the API I've been relying on.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
large This is going to take a lot longer than most things markdown Functionality involving the Markdown processor
Projects
None yet
Development

No branches or pull requests

1 participant