Documentation is self-contradictory regarding Windows-supported file permissions
还没有人认领这个 Issue。
评估
- 难度
- 2/5
- 预计耗时
- 1-3 小时
- 新手友好度
- 25/100
- Issue 类型
- 文档
- 描述清晰度
- 描述清楚
- 活跃度
- 停滞
- 技术栈
- python
调研方向
首先检查已链接的 PR gh-101694 的状态。将 os.chmod 和 stat 文档中的 Windows 权限说明与 Lib/stat.py 中的相关注释进行比较;三处的术语保持一致即表示完成。
由索引模型根据 Issue 内容生成。
描述
Documentation
One the one hand, the os.chmod documentation says that Windows only supports stat.S_IWRITE and stat.S_IREAD.
But on the other hand, the stat module documentation says that both of those (S_IWRITE and S_IREAD) are Unix V7 synonyms for S_IWUSR and S_IRUSR (and in fact comments in the stat code say the same thing).
That's confusing. One piece of documentation says Windows supports them (in fact, only them) and another piece of documentation says they're for Unix (i.e. not Windows).
The naming "IWUSR" and "IRUSR" implies the typical Unix permission model, which does not apply on Windows, so it makes sense that Windows code should ideally not use S_IWUSR or S_IRUSR (even though the code would happen to work because the values are identical to S_IWRITE and S_IREAD).
Therefore, I think the fix should be to replace the "Unix V7 synonym for ..." statements with "Unix V7 synonym for ..., also used on Windows" in both of the following:
- comments in the
statmodule code - statements in the
statdocumentation
Linked PRs
- gh-101694
- 主要语言
- Python
- 星标
- 77.2k
- 派生
- 36k
- 平均合并
- 1 天 9 小时
- 30 天内合并 PR
- 558
贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
python/cpython 的其他 Issue
-
docs pending
难度 2/5 1-3 小时 新手友好度 78/100
-
stdlib type-feature
难度 2/5 1-3 小时 新手友好度 78/100
-
stdlib type-feature
难度 2/5 1-3 小时 新手友好度 72/100
-
build type-bug
难度 2/5 1-3 小时 新手友好度 76/100
-
stdlib topic-email type-feature
难度 2/5 1-3 小时 新手友好度 70/100
相似的 Issue
-
难度 2/5 1-3 小时 新手友好度 65/100
qgis/QGIS-Documentation#11275 ·
-
bug priority:normal ready-for-dev
难度 2/5 1-3 小时 新手友好度 88/100
OpenHands/extensions#626 · 1 条评论 ·
-
难度 1/5 1 小时以内 新手友好度 90/100
CSCfi/sd-search-api#39 ·
-
难度 1/5 1 小时以内 新手友好度 90/100
-
难度 2/5 1-3 小时 新手友好度 68/100
StevenBlack/hosts#3255 ·