python / python/cpython

The explanation of "Annotating callable objects" section should be made better

オープン
#145,577 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

docs topic-typing
主要言語
Python
スター
77.2k
フォーク
35.9k
PR マージ指標
PR 指標を取得中

説明

Documentation

*Notes:

  • Python 3.14.3
  • Related: #145602

In the explanation of Annotating callable objects section, some words or sentence aren't clear, distinct, specific, concise and less common, and the word argument is misused, etc. So they should be corrected:

<Some examples>
The 1st one:

*Notes:

  • "has" is better than "takes" because "takes" sounds taking an argument but not parameter:

... a function that takes a single parameter of type int and returns a str.

... a function that has a single parameter of type int and returns a str.

The 2nd one:

*Notes:

  • Naming and calling [] "type specification" is more understandable than "subscription syntax".
  • "must" is enough for emphasis so "always" and "exactly" aren't needed, emphasizing too much.
  • "two objects" are better than "two values" because "two values" sounds actual values like v = "Hello"'s "Hello" so it's confusing while talking about types.
  • "parameter type list" is better than "argument list" because "parameter" is correct and "type list" is more specific and understandable.

The subscription syntax must always be used with exactly two values: the
argument list and the return type.

The type specification [] must have two objects, a parameter type list and return type.

etc.
Linked PRs
  • gh-145576
  • gh-145598

コントリビューションガイド

コントリビューションガイドを開く

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

調査の方向性

Python typing ドキュメントの「Annotating callable objects」セクションから始め、文言の例と関連する issue #145602、#145576、#145598 をコンテキストとして使用してください。提案されている用語と文の変更を確認し、そのセクション全体でパラメーター、引数、オブジェクト、型が明確に区別されていることを確認してください。

索引モデルが issue の本文から書いたものです。

評価

技術スタック
python
領域
documentation
issue の種類
ドキュメント
難易度
2/5
見積もり時間
1〜3時間
活発さ
停滞
明瞭さ
おおむね明確
初心者へのやさしさ
35/100

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。