Repository navigation
Commit a08a6f9
committed
docs(client): complete the Args blocks in ClientSession
`read_resource`, `send_request`, `call_tool` and `get_prompt` each document only
the input-required kwargs. The block was written once and copied, so every one
of them hides the parameters a caller has to pass:
- `send_request` documented `metadata` and omitted `request`, `result_type`,
`request_read_timeout_seconds`, `progress_callback`.
- `read_resource` omitted `uri` — the only parameter without a default — and
`meta`.
- `call_tool` omitted `name`, `arguments`, `read_timeout_seconds`,
`progress_callback`, `meta`.
- `get_prompt` omitted `name`, `arguments`, `meta`.
Docstrings only: an AST comparison against the previous head is identical once
docstrings are excluded, and every parameter of the four methods now appears in
its Args block. `pytest tests/client/test_session.py` -> 94 passed;
`ruff check` and `ruff format --check` pass.1 parent 77001c9 commit a08a6f9
1 file changed
Lines changed: 14 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
548 | 548 | | |
549 | 549 | | |
550 | 550 | | |
| 551 | + | |
| 552 | + | |
| 553 | + | |
551 | 554 | | |
| 555 | + | |
552 | 556 | | |
553 | 557 | | |
554 | 558 | | |
| |||
942 | 946 | | |
943 | 947 | | |
944 | 948 | | |
| 949 | + | |
945 | 950 | | |
946 | 951 | | |
| 952 | + | |
947 | 953 | | |
948 | 954 | | |
949 | 955 | | |
| |||
1070 | 1076 | | |
1071 | 1077 | | |
1072 | 1078 | | |
| 1079 | + | |
| 1080 | + | |
| 1081 | + | |
| 1082 | + | |
1073 | 1083 | | |
1074 | 1084 | | |
| 1085 | + | |
1075 | 1086 | | |
1076 | 1087 | | |
1077 | 1088 | | |
| |||
1227 | 1238 | | |
1228 | 1239 | | |
1229 | 1240 | | |
| 1241 | + | |
| 1242 | + | |
1230 | 1243 | | |
1231 | 1244 | | |
| 1245 | + | |
1232 | 1246 | | |
1233 | 1247 | | |
1234 | 1248 | | |
| |||
0 commit comments