pypa / setuptools

Official project repository for the Setuptools build system
https://pypi.org/project/setuptools/
MIT License
2.34k stars 1.14k forks source link

Uses RST substitution to put badges in 1 line #4312

Closed shenxianpeng closed 3 weeks ago

shenxianpeng commented 4 weeks ago

Summary of changes

It might be some update to Github's RST renderer caused badges to display in multiple lines. uses RST substitution to put badges in 1 line.

Before the change

image

After the change

image

Pull Request Checklist

[PR docs]: https://setuptools.pypa.io/en/latest/development/developer-guide.html#making-a-pull-request

abravalheri commented 4 weeks ago

Thank you very much @shenxianpeng! That was a good catch, I haven't noticed this before your PR.

I think that is a fine change, but I wonder if the best approach would not be to notify GitHub about this regression? (The rationale is that with this change we fix setuptools, but there is a lot of other repositories out there with the same setup; so if GitHub fixes it at the source, everyone benefits).

Should we notify GitHub first and then see their feedback before merging the change?

UPDATE: https://github.com/github/markup/issues/1801

shenxianpeng commented 4 weeks ago

That would be best if GitHub could address this issue.

shenxianpeng commented 4 weeks ago

I see that there are nearly no replies from the maintainer under https://github.com/github/markup/issues. Perhaps reposting https://github.com/github/markup/issues/1801 to the GitHub community discussions would get it more widespread attention. I see other questions about RST, such as 113792 (another recent regression), but not this one.

abravalheri commented 3 weeks ago

Thanks @shenxianpeng, I found an open discussion on the topic and reported the problem description there: https://github.com/orgs/community/discussions/114690

webknjaz commented 3 weeks ago

It might be some update to Github's RST renderer caused badges to display in multiple lines

Yes, I noticed this in many other of my projects. It also looks like they've broken rendering of other things and the overall support of RST on GitHub has always been quite limited. So I think this is a good change for now but in the future it might make sense to migrate to MyST and regular Markdown...

abravalheri commented 3 weeks ago

Thank you @shenxianpeng, let's merge it for now... I don't know how long the discussion on the github site will take.

Also the behaviour seems to be an intended change in docutils (¿ possibly ?) as per https://github.com/github/markup/issues/1801#issuecomment-2073622114