René's URL Explorer Experiment


Title: refactor: move streamable HTTP app creation from FastMCP to lowlevel Server by maxisbey · Pull Request #1899 · modelcontextprotocol/python-sdk · GitHub

Open Graph Title: refactor: move streamable HTTP app creation from FastMCP to lowlevel Server by maxisbey · Pull Request #1899 · modelcontextprotocol/python-sdk

X Title: refactor: move streamable HTTP app creation from FastMCP to lowlevel Server by maxisbey · Pull Request #1899 · modelcontextprotocol/python-sdk

Description: Summary Moves the Starlette app creation logic for streamable HTTP transport from FastMCP down to the lowlevel Server, and relocates StreamableHTTPASGIApp to streamable_http_manager.py. Changes Move streamable_http_app() implementation to lowlevel Server: The Starlette app creation (routes, middleware, auth setup) now lives in the lowlevel Server class. FastMCP's method becomes a thin wrapper that passes through its settings. Move StreamableHTTPASGIApp to streamable_http_manager.py: This ASGI app class directly wraps StreamableHTTPSessionManager, so it belongs in the same module. Add session_manager property to lowlevel Server: Exposes the session manager after streamable_http_app() is called. FastMCP's property now delegates to this. Fix circular import: Use TYPE_CHECKING in streamable_http_manager.py for the Server import since it's only needed for type annotations. Why The lowlevel Server shouldn't depend on FastMCP. Previously, it imported StreamableHTTPASGIApp from FastMCP, inverting the expected dependency hierarchy. This refactor ensures dependencies flow in one direction: FastMCP → lowlevel.

Open Graph Description: Summary Moves the Starlette app creation logic for streamable HTTP transport from FastMCP down to the lowlevel Server, and relocates StreamableHTTPASGIApp to streamable_http_manager.py. Changes M...

X Description: Summary Moves the Starlette app creation logic for streamable HTTP transport from FastMCP down to the lowlevel Server, and relocates StreamableHTTPASGIApp to streamable_http_manager.py. Changes M...

Opengraph URL: https://github.com/modelcontextprotocol/python-sdk/pull/1899

X: @github

direct link

Domain: patch-diff.githubusercontent.com

route-pattern/:user_id/:repository/pull/:id/files(.:format)
route-controllerpull_requests
route-actionfiles
fetch-noncev2:1ad27205-117d-b462-26e0-3377fe36d6d7
current-catalog-service-hashae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b
request-idA80C:18334E:584D6F8:77BABA3:696E21AC
html-safe-noncee8627627c0696885ce602f303eae072b4a7adc7e805c57a8a9eac2b86798956d
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJBODBDOjE4MzM0RTo1ODRENkY4Ojc3QkFCQTM6Njk2RTIxQUMiLCJ2aXNpdG9yX2lkIjoiNDU5NjI4NDkwMzEyNzkxNjk3MiIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9
visitor-hmac82cb7f03b1c18ec7c7288ffcb9988827d6c15905bb0a83dbc2cf0174dedb6192
hovercard-subject-tagpull_request:3182044677
github-keyboard-shortcutsrepository,pull-request-list,pull-request-conversation,pull-request-files-changed,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///pull_requests/show/files
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/modelcontextprotocol/python-sdk/pull/1899/files
twitter:imagehttps://avatars.githubusercontent.com/u/224885523?s=400&v=4
twitter:cardsummary_large_image
og:imagehttps://avatars.githubusercontent.com/u/224885523?s=400&v=4
og:image:altSummary Moves the Starlette app creation logic for streamable HTTP transport from FastMCP down to the lowlevel Server, and relocates StreamableHTTPASGIApp to streamable_http_manager.py. Changes M...
og:site_nameGitHub
og:typeobject
hostnamegithub.com
expected-hostnamegithub.com
None2fbe8cba5e260284c10af515699ff9bb2d6ace05ab6c2e2e585b71d93b2812c3
turbo-cache-controlno-preview
diff-viewunified
go-importgithub.com/modelcontextprotocol/python-sdk git https://github.com/modelcontextprotocol/python-sdk.git
octolytics-dimension-user_id182288589
octolytics-dimension-user_loginmodelcontextprotocol
octolytics-dimension-repository_id862584018
octolytics-dimension-repository_nwomodelcontextprotocol/python-sdk
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id862584018
octolytics-dimension-repository_network_root_nwomodelcontextprotocol/python-sdk
turbo-body-classeslogged-out env-production page-responsive full-width
disable-turbotrue
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
release7fb3bc5c995a876085291706b75cf9b08900c338
ui-targetfull
theme-color#1e2327
color-schemelight dark

Links:

Skip to contenthttps://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/files#start-of-content
https://patch-diff.githubusercontent.com/
Sign in https://patch-diff.githubusercontent.com/login?return_to=https%3A%2F%2Fgithub.com%2Fmodelcontextprotocol%2Fpython-sdk%2Fpull%2F1899%2Ffiles
GitHub CopilotWrite better code with AIhttps://github.com/features/copilot
GitHub SparkBuild and deploy intelligent appshttps://github.com/features/spark
GitHub ModelsManage and compare promptshttps://github.com/features/models
MCP RegistryNewIntegrate external toolshttps://github.com/mcp
ActionsAutomate any workflowhttps://github.com/features/actions
CodespacesInstant dev environmentshttps://github.com/features/codespaces
IssuesPlan and track workhttps://github.com/features/issues
Code ReviewManage code changeshttps://github.com/features/code-review
GitHub Advanced SecurityFind and fix vulnerabilitieshttps://github.com/security/advanced-security
Code securitySecure your code as you buildhttps://github.com/security/advanced-security/code-security
Secret protectionStop leaks before they starthttps://github.com/security/advanced-security/secret-protection
Why GitHubhttps://github.com/why-github
Documentationhttps://docs.github.com
Bloghttps://github.blog
Changeloghttps://github.blog/changelog
Marketplacehttps://github.com/marketplace
View all featureshttps://github.com/features
Enterpriseshttps://github.com/enterprise
Small and medium teamshttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
App Modernizationhttps://github.com/solutions/use-case/app-modernization
DevSecOpshttps://github.com/solutions/use-case/devsecops
DevOpshttps://github.com/solutions/use-case/devops
CI/CDhttps://github.com/solutions/use-case/ci-cd
View all use caseshttps://github.com/solutions/use-case
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
View all industrieshttps://github.com/solutions/industry
View all solutionshttps://github.com/solutions
AIhttps://github.com/resources/articles?topic=ai
Software Developmenthttps://github.com/resources/articles?topic=software-development
DevOpshttps://github.com/resources/articles?topic=devops
Securityhttps://github.com/resources/articles?topic=security
View all topicshttps://github.com/resources/articles
Customer storieshttps://github.com/customer-stories
Events & webinarshttps://github.com/resources/events
Ebooks & reportshttps://github.com/resources/whitepapers
Business insightshttps://github.com/solutions/executive-insights
GitHub Skillshttps://skills.github.com
Documentationhttps://docs.github.com
Customer supporthttps://support.github.com
Community forumhttps://github.com/orgs/community/discussions
Trust centerhttps://github.com/trust-center
Partnershttps://github.com/partners
GitHub SponsorsFund open source developershttps://github.com/sponsors
Security Labhttps://securitylab.github.com
Maintainer Communityhttps://maintainers.github.com
Acceleratorhttps://github.com/accelerator
Archive Programhttps://archiveprogram.github.com
Topicshttps://github.com/topics
Trendinghttps://github.com/trending
Collectionshttps://github.com/collections
Enterprise platformAI-powered developer platformhttps://github.com/enterprise
GitHub Advanced SecurityEnterprise-grade security featureshttps://github.com/security/advanced-security
Copilot for BusinessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/premium-support
Pricinghttps://github.com/pricing
Search syntax tipshttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
documentationhttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
Sign in https://patch-diff.githubusercontent.com/login?return_to=https%3A%2F%2Fgithub.com%2Fmodelcontextprotocol%2Fpython-sdk%2Fpull%2F1899%2Ffiles
Sign up https://patch-diff.githubusercontent.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fpull_requests%2Fshow%2Ffiles&source=header-repo&source_repo=modelcontextprotocol%2Fpython-sdk
Reloadhttps://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/files
Reloadhttps://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/files
Reloadhttps://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/files
modelcontextprotocol https://patch-diff.githubusercontent.com/modelcontextprotocol
python-sdkhttps://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk
Notifications https://patch-diff.githubusercontent.com/login?return_to=%2Fmodelcontextprotocol%2Fpython-sdk
Fork 3k https://patch-diff.githubusercontent.com/login?return_to=%2Fmodelcontextprotocol%2Fpython-sdk
Star 21.2k https://patch-diff.githubusercontent.com/login?return_to=%2Fmodelcontextprotocol%2Fpython-sdk
Code https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk
Issues 239 https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/issues
Pull requests 94 https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pulls
Actions https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/actions
Projects 0 https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/projects
Security Uh oh! There was an error while loading. Please reload this page. https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/security
Please reload this pagehttps://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/files
Insights https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pulse
Code https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk
Issues https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/issues
Pull requests https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pulls
Actions https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/actions
Projects https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/projects
Security https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/security
Insights https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pulse
Sign up for GitHub https://patch-diff.githubusercontent.com/signup?return_to=%2Fmodelcontextprotocol%2Fpython-sdk%2Fissues%2Fnew%2Fchoose
terms of servicehttps://docs.github.com/terms
privacy statementhttps://docs.github.com/privacy
Sign inhttps://patch-diff.githubusercontent.com/login?return_to=%2Fmodelcontextprotocol%2Fpython-sdk%2Fissues%2Fnew%2Fchoose
maxisbeyhttps://patch-diff.githubusercontent.com/maxisbey
mainhttps://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/tree/main
refactor/streamable-http-app-locationhttps://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/tree/refactor/streamable-http-app-location
Conversation 1 https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899
Commits 5 https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/commits
Checks 26 https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/checks
Files changed 4 https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/files
refactor: move streamable HTTP app creation from FastMCP to lowlevel Server https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/files#top
Show all changes 5 commits https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/files
5d3c43d refactor: move StreamableHTTPASGIApp to streamable_http module maxisbey Jan 16, 2026 https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/commits/5d3c43db2f3515ca00f4bb696554dd59f267b16a
bb67ae6 refactor: move StreamableHTTPASGIApp to streamable_http_manager module maxisbey Jan 16, 2026 https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/commits/bb67ae637204c0ef371655f58867961be5fbca08
d68c85f chore: add pragma no cover for untested branches maxisbey Jan 16, 2026 https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/commits/d68c85fffc9dfe0e3a9095c95b48fd57b8b649b2
a7117e5 docs: add migration guide entry for StreamableHTTPASGIApp move maxisbey Jan 17, 2026 https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/commits/a7117e5116a7d993d292edfabee77524281b3a79
6196f2b docs: add migration guide for StreamableHTTPASGIApp move and new lowl… maxisbey Jan 17, 2026 https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/commits/6196f2bbb66e56838238376826b7e9a27bf877d2
Clear filters https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/files
Please reload this pagehttps://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/files
Please reload this pagehttps://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/files
migration.md https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/files#diff-758ba107a728fccfdf0d098b2c06ded59127dd53ea287d630f72fb51040bc72d
server.py https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/files#diff-14a2991a8f2be5b9e60dab5fae92d2230dc23e57937ad5e5641b832d9c662738
server.py https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/files#diff-b21bf5e21c058ccfddb404c209f2d4288e4f32b121111ffc9d466638631d13e4
streamable_http_manager.py https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/files#diff-1071ee05567116cb77322c376307b9071c6212871068ccf41911fc337ed473af
docs/migration.mdhttps://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/files#diff-758ba107a728fccfdf0d098b2c06ded59127dd53ea287d630f72fb51040bc72d
View file https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/blob/6196f2bbb66e56838238376826b7e9a27bf877d2/docs/migration.md
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/{{ revealButtonHref }}
https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/files#diff-758ba107a728fccfdf0d098b2c06ded59127dd53ea287d630f72fb51040bc72d
Kludexhttps://patch-diff.githubusercontent.com/Kludex
Jan 18, 2026https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/files#r2702494690
Learn morehttps://docs.github.com/articles/managing-disruptive-comments/#hiding-a-comment
Please reload this pagehttps://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/files
https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/files#diff-758ba107a728fccfdf0d098b2c06ded59127dd53ea287d630f72fb51040bc72d
src/mcp/server/fastmcp/server.pyhttps://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/files#diff-14a2991a8f2be5b9e60dab5fae92d2230dc23e57937ad5e5641b832d9c662738
View file https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/blob/6196f2bbb66e56838238376826b7e9a27bf877d2/src/mcp/server/fastmcp/server.py
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/{{ revealButtonHref }}
https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/files#diff-14a2991a8f2be5b9e60dab5fae92d2230dc23e57937ad5e5641b832d9c662738
https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/files#diff-14a2991a8f2be5b9e60dab5fae92d2230dc23e57937ad5e5641b832d9c662738
https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/files#diff-14a2991a8f2be5b9e60dab5fae92d2230dc23e57937ad5e5641b832d9c662738
https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/files#diff-14a2991a8f2be5b9e60dab5fae92d2230dc23e57937ad5e5641b832d9c662738
https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/files#diff-14a2991a8f2be5b9e60dab5fae92d2230dc23e57937ad5e5641b832d9c662738
https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/files#diff-14a2991a8f2be5b9e60dab5fae92d2230dc23e57937ad5e5641b832d9c662738
https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/files#diff-14a2991a8f2be5b9e60dab5fae92d2230dc23e57937ad5e5641b832d9c662738
https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/files#diff-14a2991a8f2be5b9e60dab5fae92d2230dc23e57937ad5e5641b832d9c662738
src/mcp/server/lowlevel/server.pyhttps://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/files#diff-b21bf5e21c058ccfddb404c209f2d4288e4f32b121111ffc9d466638631d13e4
View file https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/blob/6196f2bbb66e56838238376826b7e9a27bf877d2/src/mcp/server/lowlevel/server.py
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/{{ revealButtonHref }}
https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/files#diff-b21bf5e21c058ccfddb404c209f2d4288e4f32b121111ffc9d466638631d13e4
https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/files#diff-b21bf5e21c058ccfddb404c209f2d4288e4f32b121111ffc9d466638631d13e4
https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/files#diff-b21bf5e21c058ccfddb404c209f2d4288e4f32b121111ffc9d466638631d13e4
https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/files#diff-b21bf5e21c058ccfddb404c209f2d4288e4f32b121111ffc9d466638631d13e4
https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/files#diff-b21bf5e21c058ccfddb404c209f2d4288e4f32b121111ffc9d466638631d13e4
https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/files#diff-b21bf5e21c058ccfddb404c209f2d4288e4f32b121111ffc9d466638631d13e4
https://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/files#diff-b21bf5e21c058ccfddb404c209f2d4288e4f32b121111ffc9d466638631d13e4
Please reload this pagehttps://patch-diff.githubusercontent.com/modelcontextprotocol/python-sdk/pull/1899/files
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Viewport: width=device-width


URLs of crawlers that visited me.