You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
when i run the process over 30 seconds it will have error:
Network error. Please check the connection to the server.
where can i extend the timeout ?
Reproduction
import re
import asyncio
from playwright.async_api import async_playwright
from langflow.custom import Component
from langflow.io import DictInput, Output
from langflow.schema import Data
from langflow.schema.message import Message
class Playwright(Component):
display_name = "Playwright"
description = "Fetch and scrape content from one or more URLs using Playwright."
icon = "layout-template"
name = "Playwright"
inputs = [
DictInput(
name="urls",
is_list=True,
display_name="URLs and selectors",
info="Key for URL, value for selector",
)
]
outputs = [
Output(display_name="Data", name="data", method="fetch_content_data"),
]
async def fetch_content_data(self) -> list[Data]:
import time
time.sleep(31)
return
Expected behavior
expect playwright able to execute more than 30 seconds
Who can help?
No response
Operating System
FROM langflowai/langflow:latest
Langflow Version
1.0.19
Python Version
3.12
Screenshot
No response
Flow File
No response
The text was updated successfully, but these errors were encountered:
To extend the timeout for the Langflow process and allow Playwright to execute for more than 30 seconds, you can adjust the timeout settings in both the Playwright configuration and the server-side process.
Playwright Configuration: In the playwright.config.ts file, increase the timeout setting. It's currently set to 120 seconds (120,000 milliseconds), but you can increase it further if needed. For example, to set it to 5 minutes:
timeout: 300*1000,
Server-Side Process: The timeout for the server-side process is configured in the src/backend/langflow/__main__.py file. The default worker timeout is set to 300 seconds. You can adjust this by setting the LANGFLOW_WORKER_TIMEOUT environment variable to a higher value if necessary.
timeout: int=typer.Option(300, help="Worker timeout in seconds."),
You can set the LANGFLOW_WORKER_TIMEOUT environment variable in your terminal or import it from a .env file to change the default timeout.
These adjustments should help prevent the network error by allowing more time for the process to complete [1][2].
Bug Description
when i run the process over 30 seconds it will have error:
Network error. Please check the connection to the server.
where can i extend the timeout ?
Reproduction
Expected behavior
expect playwright able to execute more than 30 seconds
Who can help?
No response
Operating System
FROM langflowai/langflow:latest
Langflow Version
1.0.19
Python Version
3.12
Screenshot
No response
Flow File
No response
The text was updated successfully, but these errors were encountered: