From ee6feaa2d56bc786f235ff35c6dbe8f005d57ba4 Mon Sep 17 00:00:00 2001 From: ehhuang Date: Thu, 5 Jun 2025 12:17:54 -0700 Subject: [PATCH] chore: remove dead code (#2403) # What does this PR do? ## Test Plan --- scripts/distro_codegen.py | 22 ---------------------- 1 file changed, 22 deletions(-) diff --git a/scripts/distro_codegen.py b/scripts/distro_codegen.py index d33c5de67..b59cd3481 100755 --- a/scripts/distro_codegen.py +++ b/scripts/distro_codegen.py @@ -15,11 +15,6 @@ from pathlib import Path from rich.progress import Progress, SpinnerColumn, TextColumn -from llama_stack.distribution.build import ( - SERVER_DEPENDENCIES, - get_provider_dependencies, -) - REPO_ROOT = Path(__file__).parent.parent @@ -90,23 +85,6 @@ def check_for_changes(change_tracker: ChangedPathTracker) -> bool: return has_changes -def collect_template_dependencies(template_dir: Path) -> tuple[str | None, list[str]]: - try: - module_name = f"llama_stack.templates.{template_dir.name}" - module = importlib.import_module(module_name) - - if template_func := getattr(module, "get_distribution_template", None): - template = template_func() - normal_deps, special_deps = get_provider_dependencies(template) - # Combine all dependencies in order: normal deps, special deps, server deps - all_deps = sorted(set(normal_deps + SERVER_DEPENDENCIES)) + sorted(set(special_deps)) - - return template.name, all_deps - except Exception: - return None, [] - return None, [] - - def pre_import_templates(template_dirs: list[Path]) -> None: # Pre-import all template modules to avoid deadlocks. for template_dir in template_dirs: