Increase httpx timeout for a Notion Tool (#358)
Increasing this helps with large pages
This commit is contained in:
parent
3a45d5fec0
commit
a3ff278640
2 changed files with 3 additions and 2 deletions
|
|
@ -146,8 +146,9 @@ async def get_object_metadata(
|
||||||
async def get_metadata_by_id(object_id: str) -> dict[str, Any]:
|
async def get_metadata_by_id(object_id: str) -> dict[str, Any]:
|
||||||
url = get_url("retrieve_a_page", page_id=object_id)
|
url = get_url("retrieve_a_page", page_id=object_id)
|
||||||
headers = get_headers(context)
|
headers = get_headers(context)
|
||||||
async with httpx.AsyncClient() as client:
|
async with httpx.AsyncClient(timeout=10) as client:
|
||||||
response = await client.get(url, headers=headers)
|
response = await client.get(url, headers=headers)
|
||||||
|
|
||||||
if response.status_code != 200:
|
if response.status_code != 200:
|
||||||
raise ToolExecutionError(
|
raise ToolExecutionError(
|
||||||
message="The page or database could not be found.",
|
message="The page or database could not be found.",
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
[tool.poetry]
|
[tool.poetry]
|
||||||
name = "arcade_notion_toolkit"
|
name = "arcade_notion_toolkit"
|
||||||
version = "0.1.1"
|
version = "0.1.2"
|
||||||
description = "Arcade.dev LLM tools for Notion"
|
description = "Arcade.dev LLM tools for Notion"
|
||||||
authors = ["ArcadeAI <dev@arcade.dev>"]
|
authors = ["ArcadeAI <dev@arcade.dev>"]
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue