-
-
Notifications
You must be signed in to change notification settings - Fork 33.2k
Docs: format list of errno constants as table #126680
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
base: main
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks really great, thank you!
Thanks, Andrew, but I'm not sure we should do this; even though it looks pretty neat on desktop, the result is unfortunately not very pretty on mobile. I tried separating out the |
We briefly discussed this on the Python Docs Discord:
|
BTW, the reason for removing
|
I'm not sure how important the footnotes are in this case. Looking at this PR again three weeks later, I now think this is a net win. The preview looks nice. |
I'm not sure. Perhaps @AA-Turner (or another Sphinx wizard) knows? These are generated from .. list-table::
:header-rows: 1
* - Name
- Description
* - .. data:: EPERM
- Operation not permitted |
.. list-table:: | ||
:header-rows: 1 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
See :widths:
This is relative column widths, so 1 1
would have the same effect. If you want the LHS column to be narrower then tweak the values
.. list-table:: | |
:header-rows: 1 | |
.. list-table:: | |
:header-rows: 1 | |
:widths: 50 50 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm, it seems the problem is actually that the names in the middle and end of the table are quite long and don't wrap -- e.g. scroll to errno.EPROTONOSUPPORT
/ ESOCKTNOSUPPORT
/ ENOTRECOVERABLE
. Setting widths doesn't seem to help...
📚 Documentation preview 📚: https://cpython-previews--126680.org.readthedocs.build/en/126680/library/errno.html