Code is not matched docs (typeobject.c)
オープン
まだ誰も着手していません。
type-bug
- 主要言語
- Python
- スター
- 77.2k
- フォーク
- 36k
- 平均マージ
- 1日 9時間
- マージ済み PR(30日)
- 558
説明
typeobject.c
/* Set type.__module__ */
r = _PyDict_ContainsId(type->tp_dict, &PyId___module__);
if (r < 0) {
goto fail;
}
if (r == 0) {
s = strrchr(spec->name, '.');
if (s != NULL) {
modname = PyUnicode_FromStringAndSize(
spec->name, (Py_ssize_t)(s - spec->name));
if (modname == NULL) {
goto fail;
}
r = _PyDict_SetItemId(type->tp_dict, &PyId___module__, modname);
Py_DECREF(modname);
if (r != 0)
goto fail;
} else {
if (PyErr_WarnFormat(PyExc_DeprecationWarning, 1,
"builtin type %.200s has no __module__ attribute",
spec->name))
goto fail;
}
}
https://docs.python.org/3/c-api/typeobj.html#c.PyTypeObject.tp_name
Dynamic types are still checkpointed and the document does not match the code
コントリビューションガイド
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
調査の方向性
まず、リンク先の PyTypeObject.tp_name のドキュメントを読み、その説明を typeobject.c に示されている動的型の処理と比較します。現在の動作を確認し、コードと一致するようにドキュメントを更新してから、利用可能であれば関連するドキュメントのビルドまたはチェックを検証します。
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- c, python
- 領域
- documentation
- issue の種類
- ドキュメント
- 難易度
- 3/5
- 見積もり時間
- 1〜2日
- 活発さ
- 停滞
- 明瞭さ
- おおむね明確
- 初心者へのやさしさ
- 38/100