Title: fix: add explicit type annotation for `call_tool` decorator by jayhemnani9910 · Pull Request #1826 · modelcontextprotocol/python-sdk · GitHub
Open Graph Title: fix: add explicit type annotation for `call_tool` decorator by jayhemnani9910 · Pull Request #1826 · modelcontextprotocol/python-sdk
X Title: fix: add explicit type annotation for `call_tool` decorator by jayhemnani9910 · Pull Request #1826 · modelcontextprotocol/python-sdk
Description: This pull request introduces a type alias to clarify and simplify the function signature of handlers registered with call_tool in the server.py module. The main change is the introduction and use of the CallToolHandler type alias, which improves code readability and maintainability. Type hinting and handler signature improvements: Added a CallToolHandler type alias to explicitly define the expected function signature for call tool handler functions in server.py. Updated the call_tool decorator to use the new CallToolHandler type alias, replacing the previous inline type definition for better clarity and consistency.
Open Graph Description: This pull request introduces a type alias to clarify and simplify the function signature of handlers registered with call_tool in the server.py module. The main change is the introduction and use o...
X Description: This pull request introduces a type alias to clarify and simplify the function signature of handlers registered with call_tool in the server.py module. The main change is the introduction and use o...
Opengraph URL: https://github.com/modelcontextprotocol/python-sdk/pull/1826
X: @github
Domain: github.com
| route-pattern | /:user_id/:repository/pull/:id/files(.:format) |
| route-controller | pull_requests |
| route-action | files |
| fetch-nonce | v2:db2fbca5-e543-c9cd-4e5b-ee5179aebdd0 |
| current-catalog-service-hash | ae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b |
| request-id | A48A:337C5B:425C3C2:5AE10E4:6A5E0849 |
| html-safe-nonce | e5e83732634cb17b807893255d93e67a3971394388d3664cb9efb0a4f9db32d1 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJBNDhBOjMzN0M1Qjo0MjVDM0MyOjVBRTEwRTQ6NkE1RTA4NDkiLCJ2aXNpdG9yX2lkIjoiNDI0NDE1MDQ1NTkxOTA1Mjg3MyIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | 4bd0fd424a76cd0805af7263a5af10486f54597ccc2907e4c143ac10406e8ea7 |
| hovercard-subject-tag | pull_request:3144321808 |
| github-keyboard-shortcuts | repository,pull-request-list,pull-request-conversation,pull-request-files-changed,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/modelcontextprotocol/python-sdk/pull/1826/files |
| twitter:image | https://avatars.githubusercontent.com/u/193022578?s=400&v=4 |
| twitter:card | summary_large_image |
| og:image | https://avatars.githubusercontent.com/u/193022578?s=400&v=4 |
| og:image:alt | This pull request introduces a type alias to clarify and simplify the function signature of handlers registered with call_tool in the server.py module. The main change is the introduction and use o... |
| og:site_name | GitHub |
| og:type | object |
| hostname | github.com |
| expected-hostname | github.com |
| None | 7c1de870f4c0eff05971cd22970403a1239a98dc1a35e52a43594f23fc4d546f |
| turbo-cache-control | no-preview |
| diff-view | unified |
| go-import | github.com/modelcontextprotocol/python-sdk git https://github.com/modelcontextprotocol/python-sdk.git |
| octolytics-dimension-user_id | 182288589 |
| octolytics-dimension-user_login | modelcontextprotocol |
| octolytics-dimension-repository_id | 862584018 |
| octolytics-dimension-repository_nwo | modelcontextprotocol/python-sdk |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 862584018 |
| octolytics-dimension-repository_network_root_nwo | modelcontextprotocol/python-sdk |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | true |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | e90635d4b07e4a20ff548df2e2bfea2179c6a3f3 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width