mirror of
https://github.com/langflow-ai/langflow.git
synced 2026-07-27 23:11:35 +08:00
Merge branch 'release-1.9.0' into LE-846
This commit is contained in:
@ -200,8 +200,12 @@ async def test_component_logging():
|
||||
# Log a message
|
||||
await asyncio.to_thread(component.log, "Test log message")
|
||||
|
||||
# Get the event from the queue
|
||||
event_id, event_data, _ = queue.get_nowait()
|
||||
# Get the event from the queue with timeout to avoid race conditions
|
||||
try:
|
||||
event_id, event_data, _ = await asyncio.wait_for(queue.get(), timeout=5.0)
|
||||
except asyncio.TimeoutError:
|
||||
pytest.fail("Timeout waiting for log event in queue")
|
||||
|
||||
event = event_data.decode("utf-8")
|
||||
|
||||
assert "Test log message" in event
|
||||
|
||||
Reference in New Issue
Block a user