| 102 | |
| 103 | |
| 104 | def _install_base_native(worktree: Path, repo_root: Path) -> None: |
| 105 | env: Final = { |
| 106 | **os.environ, |
| 107 | "CARGO_TARGET_DIR": str( |
| 108 | Path(os.environ.get("CARGO_TARGET_DIR", repo_root / "litellm-rust" / "target")).resolve() |
| 109 | ), |
| 110 | } |
| 111 | _run( |
| 112 | [ |
| 113 | "uv", "pip", "install", "--python", sys.executable, "--no-deps", |
| 114 | "--target", str(worktree.parent / "native-install"), "--editable", str(worktree), |
| 115 | ], |
| 116 | cwd=worktree, |
| 117 | env=env, |
| 118 | ) |
| 119 | |
| 120 | |
| 121 | def base_counts(ref: str, repo_root: Path = REPO_ROOT, checker: Path = CHECKER) -> Mapping[str, int]: |