llama-stack-mirror/llama_stack/distribution
Sébastien Han 239e4aad80
refactor: simplify command execution and remove PTY handling
A PTY is unnecessary for interactive mode since `subprocess.run()`
already inherits the calling terminal’s stdin, stdout, and stderr,
allowing natural interaction. Using a PTY can introduce unwanted
side effects like buffering issues and inconsistent signal
handling. Standard input/output is sufficient for most
interactive programs.

This commit simplifies the command execution by:

1. Removing PTY-based execution in favor of direct subprocess handling
2. Consolidating command execution into a single run_command function
3. Improving error handling with specific subprocess error types
4. Adding proper type hints and documentation
5. Maintaining Ctrl+C handling for graceful interruption

Signed-off-by: Sébastien Han <seb@redhat.com>
2025-03-14 17:52:38 +01:00
..
routers feat: Add new compact MetricInResponse type (#1593) 2025-03-12 15:45:44 -07:00
server feat: add provider API for listing and inspecting provider info (#1429) 2025-03-13 15:07:21 -07:00
store refactor: move a few tests to top-level tests/ directory 2025-03-03 17:33:39 -08:00
ui docs: update test_agents to use new Agent SDK API (#1402) 2025-03-06 15:21:12 -08:00
utils refactor: simplify command execution and remove PTY handling 2025-03-14 17:52:38 +01:00
__init__.py API Updates (#73) 2024-09-17 19:51:35 -07:00
build.py refactor: simplify command execution and remove PTY handling 2025-03-14 17:52:38 +01:00
build_conda_env.sh chore: remove straggler references to llama-models (#1345) 2025-03-01 14:26:03 -08:00
build_container.sh chore: remove straggler references to llama-models (#1345) 2025-03-01 14:26:03 -08:00
build_venv.sh chore: remove straggler references to llama-models (#1345) 2025-03-01 14:26:03 -08:00
client.py chore: move all Llama Stack types from llama-models to llama-stack (#1098) 2025-02-14 09:10:59 -08:00
common.sh fix: Fixing some small issues with the build scripts (#1132) 2025-02-19 22:20:49 -08:00
configure.py feat: add provider API for listing and inspecting provider info (#1429) 2025-03-13 15:07:21 -07:00
datatypes.py fix!: update eval-tasks -> benchmarks (#1032) 2025-02-13 16:40:58 -08:00
distribution.py feat: add provider API for listing and inspecting provider info (#1429) 2025-03-13 15:07:21 -07:00
inspect.py fix: improve signal handling and update dependencies (#1044) 2025-02-13 08:07:59 -08:00
library_client.py feat: Add back inference metrics and preserve context variables across asyncio boundary (#1552) 2025-03-12 12:01:03 -07:00
providers.py fix: OpenAPI with provider get (#1627) 2025-03-13 19:56:32 -07:00
request_headers.py feat: Add back inference metrics and preserve context variables across asyncio boundary (#1552) 2025-03-12 12:01:03 -07:00
resolver.py feat: add provider API for listing and inspecting provider info (#1429) 2025-03-13 15:07:21 -07:00
stack.py feat: add provider API for listing and inspecting provider info (#1429) 2025-03-13 15:07:21 -07:00
start_stack.sh feat(logging): implement category-based logging (#1362) 2025-03-07 11:34:30 -08:00