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