Skip to content

Add Last-modified: date and metadata to HTML view of PEPs #1564

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

Closed
nealmcb opened this issue Mar 7, 2020 · 1 comment
Closed

Add Last-modified: date and metadata to HTML view of PEPs #1564

nealmcb opened this issue Mar 7, 2020 · 1 comment
Assignees

Comments

@nealmcb
Copy link

nealmcb commented Mar 7, 2020

Is your feature request related to a problem? Please describe.
When looking at a PEP page on python.org, it isn't obvious when the PEP was last modified, or how to see recent revisions.

In addition, search engines often aren't displaying useful information. E.g. the Google result for a search of PEPs seems to show the Created: date, which may confuse searchers. E.g. the date listed for PEP 518 in a Google search is May 10, 2016, though this Provisional PEP was most recently updated on Dec 13, 2019.

Describe the solution you'd like
It would be great if the footer of the HTML rendering of each PEP, when served by python.org, included a Last-Modified: date, with a link to the GitHub history for more information. It could go after the Source link at the bottom of the page. E.g.

Including relevant dates as metadata such as datePublished and dateModified should help search engines display more helpful information, as described at Official Google Webmaster Central Blog: Help Google Search know the best date for your web page

Our documentation at PEP Page Generation — Python.org Website 1.0 documentation describes the current process.

Given the peps git repo obtained via that process, it seems to take less than 20 seconds to get the latest modification date of all the PEPs via e.g. even using the shell pipeline listed at How to retrieve the last modification date of all files in a git repository - Server Fault, so I don't think there would be much overhead to maintaining this information.

Describe alternatives you've considered
A discussion of some of the options for making PEP history clearer, or whether version numbers or changelogs for PEPs would be worthwhile, is at Easier tracking of PEP changes, versions, or modification dates - PEPs - Discussions on Python.org. The approach described here expands on what I see as the result of that discussion.

Adding Last-Modified information to the PEP 0 page might also be worthwhile, as suggested there.

@Mariatta Mariatta self-assigned this Mar 8, 2020
Mariatta added a commit that referenced this issue Mar 8, 2020
Obtain the last modified date by making GET request to GitHub.
Don't render anything if there's any error with the GET request.

Add tests, and mock the network call.

Closes #1564
AA-Turner added a commit to AA-Turner/peps that referenced this issue Aug 15, 2020
AA-Turner added a commit to AA-Turner/peps that referenced this issue Aug 15, 2020
AA-Turner added a commit to AA-Turner/peps that referenced this issue Aug 15, 2020
@hugovk
Copy link
Member

hugovk commented Aug 12, 2024

The PEPs now have their own repo: https://github.com/python/peps and own website: https://peps.python.org/ and also have "Last modified" footers that link to GitHub. For example: https://peps.python.org/pep-0750/

@nealmcb Please could you close this issue?

@hugovk hugovk closed this as completed Aug 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants
@nealmcb @hugovk @Mariatta and others