File tree Expand file tree Collapse file tree 1 file changed +11
-7
lines changed
Expand file tree Collapse file tree 1 file changed +11
-7
lines changed Original file line number Diff line number Diff line change @@ -48,10 +48,15 @@ def is_install_from_source(llama_stack_version):
4848 return "." not in llama_stack_version or "+rhai" in llama_stack_version
4949
5050
51- def check_package_installed (package_name ):
52- """Check if llama binary is installed and accessible."""
53- if not shutil .which (package_name ):
54- print (f"Error: { package_name } not found. Please install it first." )
51+ def check_command_installed (command , package_name = None ):
52+ """Check if a command is installed and accessible."""
53+ if not shutil .which (command ):
54+ if package_name :
55+ print (
56+ f"Error: { command } not found. Please run uv pip install { package_name } "
57+ )
58+ else :
59+ print (f"Error: { command } not found. Please install it." )
5560 sys .exit (1 )
5661
5762
@@ -262,11 +267,10 @@ def generate_containerfile(dependencies, llama_stack_install):
262267
263268
264269def main ():
265- check_package_installed ("uv" )
270+ check_command_installed ("uv" )
266271 install_llama_stack_from_source (LLAMA_STACK_VERSION )
267272
268- print ("Checking llama installation..." )
269- check_package_installed ("llama" )
273+ check_command_installed ("llama" , "llama-stack-client" )
270274
271275 # Do not perform version check if installing from source
272276 if not is_install_from_source (LLAMA_STACK_VERSION ):
You can’t perform that action at this time.
0 commit comments