Skip to content

RFC: Lower log levels used for connections #821

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
May 27, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/mcp/client/sse.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ async def sse_client(

async with anyio.create_task_group() as tg:
try:
logger.info(f"Connecting to SSE endpoint: {remove_request_params(url)}")
logger.debug(f"Connecting to SSE endpoint: {remove_request_params(url)}")
async with httpx_client_factory(headers=headers, auth=auth) as client:
async with aconnect_sse(
client,
Expand All @@ -73,7 +73,7 @@ async def sse_reader(
match sse.event:
case "endpoint":
endpoint_url = urljoin(url, sse.data)
logger.info(
logger.debug(
f"Received endpoint URL: {endpoint_url}"
)

Expand Down Expand Up @@ -146,7 +146,7 @@ async def post_writer(endpoint_url: str):
await write_stream.aclose()

endpoint_url = await tg.start(sse_reader)
logger.info(
logger.debug(
f"Starting post writer with endpoint URL: {endpoint_url}"
)
tg.start_soon(post_writer, endpoint_url)
Expand Down
2 changes: 1 addition & 1 deletion src/mcp/client/streamable_http.py
Original file line number Diff line number Diff line change
Expand Up @@ -463,7 +463,7 @@ async def streamablehttp_client(

async with anyio.create_task_group() as tg:
try:
logger.info(f"Connecting to StreamableHTTP endpoint: {url}")
logger.debug(f"Connecting to StreamableHTTP endpoint: {url}")

async with httpx_client_factory(
headers=transport.request_headers,
Expand Down
Loading