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

Add links to code in docstrings #3833

Open
jeffreykennethli opened this issue Dec 10, 2021 · 1 comment
Open

Add links to code in docstrings #3833

jeffreykennethli opened this issue Dec 10, 2021 · 1 comment
Labels
documentation 📜 Updates and issues with the documentation P2 Minor bugs or low-priority feature requests

Comments

@jeffreykennethli
Copy link

In our readthedocs, our docstrings often refer to other parts of the codebase, for example in read_csv_glob there is a reference to read_csv: link.

Screen Shot 2021-12-10 at 11 14 20 AM

In pandas, the docstring references contain links to other parts of the codebase. It looks like this is accomplished with rst external links, see example: https://github.com/pandas-dev/pandas/blob/945c9ed766a61c7d2c0a7cbb251b6edebf9cb7d5/pandas/io/parsers/readers.py#L56-L64 and explanation of external links with sphinx: https://sublime-and-sphinx-guide.readthedocs.io/en/latest/references.html#links-to-external-web-pages

I think this would be worth considering adding for Modin for ease of navigating the readthedocs, although it may come at the cost of making the raw docstrings (in github) harder to read.

@jeffreykennethli jeffreykennethli added the documentation 📜 Updates and issues with the documentation label Dec 10, 2021
@jeffreykennethli jeffreykennethli self-assigned this Dec 17, 2021
@jeffreykennethli
Copy link
Author

We should do something like this to make our readthedocs documentation richer: https://www.sphinx-doc.org/en/master/tutorial/describing-code.html?highlight=cross-references#cross-referencing-python-objects

@vnlitvinov vnlitvinov added the P2 Minor bugs or low-priority feature requests label Aug 26, 2022
@jeffreykennethli jeffreykennethli removed their assignment Sep 18, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation 📜 Updates and issues with the documentation P2 Minor bugs or low-priority feature requests
Projects
None yet
Development

No branches or pull requests

2 participants