Open kif opened 6 months ago
Please provide a concrete reference to a readme that contains the problematic behavior - it's unclear from the linked issue which conditions lead to the problem.
From https://github.com/PhasesResearchLab/ESPEI
python -m readme_renderer -f rst README.rst
(.txt
extension added for the upload to GitHub to work)
Gives output:
<string>:37: (WARNING/2) Cannot scale image!
Could not get size from "docs/_static/cu-mg-mcmc-phase-diagram.png":
Reading external files disabled.
Thanks for the error message, that points out a warning from docutils
.
We have disabled the ability to read external files, which prevents docutils from trying to load images to scale these. See:
I haven't looked too hard yet for what alternatives might be avilable, or if there's a way to only allow images, but now there's a reason.
This is actually a blocker to upload a new release for my project. Could this be non fatal maybe (as it used to be)? E.g. just do not render the image in that case. We just display a scaled logo in our readme. I think it is a fairly common use case.
Is the inclusion of external files considered a security risk?
I'd love to hear your opinion on that @miketheman, thank you.
As reported in: https://github.com/pypa/twine/issues/1102
twine check
fails when parsing thereadme
file contains badges. If one of the badge has a scale factor, thereadme_renderer
fails claiming it is not allowed to access to the internet.