[Chore]Fixes client startup errors (#27)
This commit is contained in:
@@ -323,7 +323,7 @@ class DorisUnifiedClient:
|
|||||||
async with streamablehttp_client(
|
async with streamablehttp_client(
|
||||||
self.config.server_url,
|
self.config.server_url,
|
||||||
timeout=timedelta(seconds=self.config.timeout)
|
timeout=timedelta(seconds=self.config.timeout)
|
||||||
) as (read, write):
|
) as (read, write, _):
|
||||||
async with ClientSession(read, write) as session:
|
async with ClientSession(read, write) as session:
|
||||||
self.session = session
|
self.session = session
|
||||||
self._init_sub_clients()
|
self._init_sub_clients()
|
||||||
@@ -463,7 +463,7 @@ async def create_http_client(server_url: str, timeout: int = 60) -> DorisUnified
|
|||||||
# Example usage
|
# Example usage
|
||||||
async def example_stdio():
|
async def example_stdio():
|
||||||
"""stdio mode example"""
|
"""stdio mode example"""
|
||||||
client = await create_stdio_client("python", ["doris_mcp_server/main.py"])
|
client = await create_stdio_client("python", ["-m", "doris_mcp_server.main", "--transport", "stdio"])
|
||||||
|
|
||||||
async def test_client(client: DorisUnifiedClient):
|
async def test_client(client: DorisUnifiedClient):
|
||||||
# Get server capabilities
|
# Get server capabilities
|
||||||
|
|||||||
Reference in New Issue
Block a user