Clarify usage of type hints in the standard-library modules

未關閉
#1,304 0 則留言 1 個 reaction 已指派 0 人 在 GitHub 檢視

還沒有人認領這個 Issue。

評估

難度
2/5
預估耗時
1-3 小時
新手友好度
48/100
Issue 類型
文件
描述清晰度
基本清楚
活躍度
停滯
技術堆疊
python
領域
documentation

研究方向

首先查看連結的討論和 pull request 評論,了解目前的政策及其依據,然後找到適當的 devguide 文件頁面。當指南正式說明標準函式庫的型別提示政策,包括其依據和例外情況時,即視為完成。

由索引模型根據 Issue 內容生成。

描述

topic-dev process topic-stdlib type-feature

I think that Alex summarized the issue pretty well:

In general our policy is currently not to add type hints to standard-library modules in the Lib/ directory (there are some exceptions, but they're all pretty specific). I think we still have yet to add some formal documentation around this in the devguide (we really need to!), but you can see some rationales here:

Originally posted by @AlexWaygood in https://github.com/python/cpython/pull/117583#discussion_r1556105954

主要語言
Python
星號
2.1k
分支
1k
平均合併
2 天 12 小時
30 天內合併 PR
12

貢獻指南

開啟貢獻指南

從這裡開始

  1. 先讀完整個 Issue,再讀專案的貢獻指南。
  2. 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
  3. Fork 儲存庫,在一個分支上完成修改。
  4. 送出 Pull Request,並在描述裡引用這個 Issue 編號。

python/devguide 的其他 Issue

查看 python/devguide 的全部 Issue

相似的 Issue

更多 Python Issue

把新 issue 寄到你的電子郵件信箱

精選適合新手參與的 GitHub issue 摘要。