TheAlgorithms / TheAlgorithms/Python
Suggestion: adopt a documentation format for docstring
未關閉
還沒有人認領這個 Issue。
awaiting reviews
- 主要語言
- Python
- 星號
- 225k
- 分支
- 51.1k
- 平均合併
- 1 天 23 小時
- 30 天內合併 PR
- 156
描述
As the number of algorithms are increasing, it might make sense to adopt a single documentation format for docstrings. Following are existing currently:
- Google Docstring: https://google.github.io/styleguide/pyguide.html#s3.8-comments-and-docstrings
- Numpydoc: https://numpydoc.readthedocs.io/en/latest/format.html
- Sphinx: https://sphinx-rtd-tutorial.readthedocs.io/en/latest/docstrings.html
There are editor extensions which help in generating the docstring based on the chosen format like:
The doctest will come under the examples section for each of the above format.
貢獻指南
從這裡開始
- 先讀完整個 Issue,再讀專案的貢獻指南。
- 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
- Fork 儲存庫,在一個分支上完成修改。
- 送出 Pull Request,並在描述裡引用這個 Issue 編號。
研究方向
首先比較 issue 中連結的 Google Docstring、Numpydoc 和 Sphinx 格式,包括每種格式如何處理 doctest 範例。查看討論,以確定專案是否已選擇一種格式。當已有共識的文件格式,以及將其套用到演算法 docstring 的明確定義方式時,即視為完成。
由索引模型根據 Issue 內容生成。
評估
- 技術堆疊
- python
- 領域
- documentation
- Issue 類型
- 功能
- 難度
- 5/5
- 預估耗時
- 一週以上
- 活躍度
- 活躍
- 描述清晰度
- 需要釐清
- 新手友好度
- 25/100