The explanation of "Annotating callable objects" section should be made better
Chưa có ai nhận issue này.
- Ngôn ngữ chính
- Python
- Star
- 77.2k
- Fork
- 35.9k
- Chỉ số merge pull request
- Chỉ số pull request đang chờ
Mô tả
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
intand returns astr.
... a function that has a single parameter of type
intand returns astr.
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
Hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Hướng nghiên cứu
Bắt đầu với phần "Annotating callable objects" trong tài liệu Python typing, sử dụng các ví dụ về cách diễn đạt và các issue liên quan #145602, #145576 và #145598 làm ngữ cảnh. Xem xét thuật ngữ và các thay đổi câu được đề xuất, sau đó xác nhận rằng phần này sử dụng nhất quán các phân biệt rõ ràng giữa tham số, đối số, đối tượng và kiểu.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Đánh giá
- Công nghệ
- python
- Lĩnh vực
- documentation
- Loại issue
- Tài liệu
- Độ khó
- 2/5
- Thời gian dự kiến
- 1-3 giờ
- Mức độ hoạt động
- Đình trệ
- Độ rõ ràng
- Khá rõ ràng
- Mức phù hợp với người mới
- 35/100