[PR #351] [MERGED] feat: add get_task_result_stream to new client #410

Closed
opened 2026-02-16 01:17:14 -05:00 by yindo · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/run-llama/llama_deploy/pull/351
Author: @masci
Created: 11/6/2024
Status: Merged
Merged: 11/8/2024
Merged by: @masci

Base: mainHead: massi/client-streaming


📝 Commits (3)

  • aac367c feat: add get_task_result_stream to new client
  • 62ee7f4 prevent using the sync client within an async loop
  • 9ac6ea6 remove debug print

📊 Changes

7 files changed (+204 additions, -30 deletions)

View changed files

📝 e2e_tests/basic_streaming/test_run_client.py (+10 -22)
📝 llama_deploy/client/client.py (+8 -1)
📝 llama_deploy/client/models/core.py (+34 -1)
📝 llama_deploy/client/models/model.py (+29 -5)
📝 tests/client/models/test_core.py (+95 -0)
📝 tests/client/models/test_model.py (+18 -1)
📝 tests/client/test_client.py (+10 -0)

📄 Description

This PR ports the last method missing from AsyncSessionClient, get_task_result_stream.

Fixes https://github.com/run-llama/llama_deploy/issues/335

Notes for the reviewer:

  • async methods returning Coroutine[AsyncGenerator] when converted with async_to_sync return AsyncGenerator, that we can't use in sync calls. To overcome this limitation, generator_wrapper was added that consumes the async generator under the hood and returns a list
  • end-to-end tests were update to use Client
  • unit tests were added to cover the new wrapper

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/run-llama/llama_deploy/pull/351 **Author:** [@masci](https://github.com/masci) **Created:** 11/6/2024 **Status:** ✅ Merged **Merged:** 11/8/2024 **Merged by:** [@masci](https://github.com/masci) **Base:** `main` ← **Head:** `massi/client-streaming` --- ### 📝 Commits (3) - [`aac367c`](https://github.com/run-llama/llama_deploy/commit/aac367c91a42e2761545c086868d1cd0514e9fcc) feat: add get_task_result_stream to new client - [`62ee7f4`](https://github.com/run-llama/llama_deploy/commit/62ee7f4dbbfdeaf95886a1f3177ffcecc2fc835a) prevent using the sync client within an async loop - [`9ac6ea6`](https://github.com/run-llama/llama_deploy/commit/9ac6ea65685fe542131001c1458fa816578447e0) remove debug print ### 📊 Changes **7 files changed** (+204 additions, -30 deletions) <details> <summary>View changed files</summary> 📝 `e2e_tests/basic_streaming/test_run_client.py` (+10 -22) 📝 `llama_deploy/client/client.py` (+8 -1) 📝 `llama_deploy/client/models/core.py` (+34 -1) 📝 `llama_deploy/client/models/model.py` (+29 -5) 📝 `tests/client/models/test_core.py` (+95 -0) 📝 `tests/client/models/test_model.py` (+18 -1) 📝 `tests/client/test_client.py` (+10 -0) </details> ### 📄 Description This PR ports the last method missing from `AsyncSessionClient`, `get_task_result_stream`. Fixes https://github.com/run-llama/llama_deploy/issues/335 Notes for the reviewer: - async methods returning `Coroutine[AsyncGenerator]` when converted with `async_to_sync` return `AsyncGenerator`, that we can't use in sync calls. To overcome this limitation, `generator_wrapper` was added that consumes the async generator under the hood and returns a list - end-to-end tests were update to use `Client` - unit tests were added to cover the new wrapper --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
yindo added the pull-request label 2026-02-16 01:17:14 -05:00
yindo closed this issue 2026-02-16 01:17:14 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: run-llama/llama_deploy#410