-
Notifications
You must be signed in to change notification settings - Fork 301
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
Use Markdown and text renderers in check
#876
Comments
For |
Maybe we need better comments explaining why rendering cannot fail so that this is more easily self-discoverable in the future? |
Is there any harm in running them anyway? Maybe those renderers could fail in the future? |
I don't think there's any harm, per se, but it's just strictly not necessary and I can't imagine it ever being necessary. One of the advantages to these formats, specifically Markdown, is that they can still render all the valid syntax in a document even if there is a syntax error or some content is malformed (unlike reStructuredText, where rendering is a pass/fail). So, any change that would alter this sort of fundamental property of Markdown. If such a change ever did happen, I'd definitely be opposed to including it at any point in our Markdown rendering pipeline. I think it's important for PyPI to continue accepting any Markdown, no matter what it produces. Similarly plain text is just plain text -- the actual 'rendering' is a no-op here. The other things we do to these formats (html escaping, cleaning, etc) will also never cause the render to fail, so running them is unnecessary as well. |
What's your goal here @bhrutledge ? What problem are you trying to fix? |
A combination of not understanding a perceived discrepancy between Twine and Warehouse, and possibly future-proofing Twine. I understand now, and it turns out that using the Markdown renderer requires installing Thanks @di for the explanation. |
Related to #875, I was reminded that Twine doesn't actually "check" these file types:
twine/twine/commands/check.py
Lines 28 to 33 in 0f7a68b
However, Readme Renderer has renderers for these file types. On the surface, it looks like they're unlikely to issue warnings, but it seems like using them would be harmless and potentially beneficial in the future.
@di as an author of
check
and maintainer of Readme Renderer, what do you think?The text was updated successfully, but these errors were encountered: