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

PEP 1: Use plain text formatting and fix links #2259

Merged
merged 5 commits into from
Jan 23, 2022

Conversation

hugovk
Copy link
Member

@hugovk hugovk commented Jan 23, 2022

Prep for PEP 676, which will give syntax highlighting. By default Python formatting is used:

image

https://python.github.io/peps/pep-0001/#pep-header-preamble

But we want plain text formatting here.


Also update some links to their newly redirected location.

And delete this one:

* `Frequently Asked Questions for Developers
  <http://docs.python.org/devguide/faq.html>`_

Because it redirects to 404 https://devguide.python.org/faq/

Checking the Internet Archive (https://web.archive.org/web/20120301112706/http://docs.python.org/devguide/faq.html#how-do-i-tell-who-is-and-isn-t-a-core-developer) I don't see a matching page on the new devguide?

@CAM-Gerlach CAM-Gerlach changed the title PEP 1:Use plain text formatting and fix links PEP 1: Use plain text formatting and fix links Jan 23, 2022
@AA-Turner
Copy link
Member

I think we need to discuss how to deal with updating code blocks for the correct 'highlighting type' across all PEPs -- or if we care. (If the default is Python, then perhaps updating e.g. C, text/plain, etc blocks is feasible)

A

Copy link
Member

@CAM-Gerlach CAM-Gerlach left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A few minor suggestions related to links. Thanks!

pep-0001.txt Outdated Show resolved Hide resolved
pep-0001.txt Outdated
@@ -738,7 +740,7 @@ Once the PEP is ready for the repository, a PEP editor will:
status as "Draft".

* Add the PEP to a local fork of the PEP repository. For workflow
instructions, follow `The Python Developers Guide <http://docs.python.org/devguide>`_
instructions, follow `The Python Developers Guide <https://devguide.python.org/>`_

The git repo for the peps is::
Copy link
Member

@CAM-Gerlach CAM-Gerlach Jan 23, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Given you've updated the other links, may as well not still use a verbatim block that the user has to manually copy, paste and navigate to in their browser instead of simply a link. I suggest just deleting this block and making the change above instead to link it

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, like this? cb1fdfe

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry, I meant just deleting the whole block (couldn't make it a suggestion as it was outside the scope GitHub would let me), since the PEP repo is already referred to and directly linked two lines above, so restating that is now redundant.

pep-0001.txt Outdated Show resolved Hide resolved
Copy link
Member

@AA-Turner AA-Turner left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks Hugo, looks good
A

pep-0001.txt Outdated

https://github.com/python/peps
The Git repo for the peps is https://github.com/python/peps
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If we're changing this line, might as well update the capitalisation to be consistent.

Suggested change
The Git repo for the peps is https://github.com/python/peps
The Git repo for the PEPs is https://github.com/python/peps

Copy link
Member

@CAM-Gerlach CAM-Gerlach Jan 23, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
The Git repo for the peps is https://github.com/python/peps

I suggest simply eliminating this line, since the PEP repo is already introduced and directly linked a couple lines above at this same URL.

@CAM-Gerlach
Copy link
Member

I think we need to discuss how to deal with updating code blocks for the correct 'highlighting type' across all PEPs -- or if we care. (If the default is Python, then perhaps updating e.g. C, text/plain, etc blocks is feasible)

Good point. My intuition from reading a lot of PEPs is that the vast majority are Python, with a small but non-trivial fraction in C, and a handful in other languages; the number of plain-text verbatim blocks are likely somewhere between very small and modest. If desired, I could do a formal survey of a representative sample of PEPs; informally sampling single-line grep results, and a slightly less random sample of multi-line results, this conjecture seems to be generally supported.

While I don't want to create major churn on older PEPs, it should only affect a relatively small number of them (likely considerably fewer than #2209 ), and not making the change would be a display regression from the author's intent and the PEP's original rendering. Therefore, I'd suggest continuing to default to Python (which is the most sensible default here and minimizes work for authors) and just updating those PEPs (or at the very least, "active" PEPs). I could help take care of that

@hugovk hugovk force-pushed the pep1-fix-links-formatting branch from cb1fdfe to 9799ad2 Compare January 23, 2022 21:34
@AA-Turner AA-Turner merged commit 36ce796 into python:main Jan 23, 2022
@AA-Turner
Copy link
Member

Merged, thanks Hugo

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants