This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: Missing links to Source Code in Documentation pages
Type: enhancement Stage: patch review
Components: Documentation Versions: Python 3.10, Python 3.9, Python 3.8, Python 3.7
process
Status: open Resolution:
Dependencies: Superseder:
Assigned To: docs@python Nosy List: docs@python, edison.abahurire, eric.araujo, ezio.melotti, mdk, python-dev, remi.lapeyre, willingc
Priority: normal Keywords: patch

Created on 2020-06-07 00:20 by edison.abahurire, last changed 2022-04-11 14:59 by admin.

Pull Requests
URL Status Linked Edit
PR 20843 open python-dev, 2020-06-12 21:20
Messages (3)
msg370863 - (view) Author: Edison Abahurire (edison.abahurire) * Date: 2020-06-07 00:20
Just below the Module heading, most library documenation pages like https://docs.python.org/3/library/datetime.html have a link to the source code in the form of `Source code: Lib/datetime.py` that links to the cpython github file of that module.

Some modules like https://docs.python.org/3/library/time.html are missing this though and yet I think it would be quite useful for people who want to navigate the depths of the implementation.

Now, the challenge is that most modules are not located in single code files but what if, instead of leaving it blank, we link to the folder that contains the code of that module? Wouldn't that be helpful?

For example:
For https://docs.python.org/3/library/wsgiref.html, we can add this https://github.com/python/cpython/tree/master/Lib/wsgiref as the link to source code.
msg370881 - (view) Author: Rémi Lapeyre (remi.lapeyre) * Date: 2020-06-07 08:24
In the case of time, it's a C module. Those usually don't have a link to their implementation at the top. Others like wsgiref should have a link as having a quick way to read the implementation is a nice way to check on the implementation details and get acquainted with Python's internal.

Could you open a PR to add those?
msg370900 - (view) Author: Edison Abahurire (edison.abahurire) * Date: 2020-06-07 14:22
Thanks for the review. 
I'll open a PR.
History
Date User Action Args
2022-04-11 14:59:32adminsetgithub: 85073
2020-06-12 21:20:39python-devsetkeywords: + patch
nosy: + python-dev

pull_requests: + pull_request20036
stage: patch review
2020-06-07 14:22:10edison.abahuriresetmessages: + msg370900
2020-06-07 08:24:45remi.lapeyresetnosy: + remi.lapeyre

messages: + msg370881
versions: + Python 3.7, Python 3.8, Python 3.9, Python 3.10
2020-06-07 00:20:06edison.abahurirecreate