Make shutil rename in python_only_dev (#10233)

Signed-off-by: shcheglovnd <shcheglovnd@avride.ai>
This commit is contained in:
Nikolai Shcheglov 2024-11-11 16:29:19 -06:00 committed by GitHub
parent 9d5b4e4dea
commit 08f93e7439
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -69,7 +69,8 @@ if not args.quit_dev:
current_vllm_path = os.path.join(cwd, "vllm") current_vllm_path = os.path.join(cwd, "vllm")
print(f"Renaming {pre_built_vllm_path} to {tmp_path} for backup") print(f"Renaming {pre_built_vllm_path} to {tmp_path} for backup")
os.rename(pre_built_vllm_path, tmp_path) shutil.copytree(pre_built_vllm_path, tmp_path)
shutil.rmtree(pre_built_vllm_path)
print(f"Linking {current_vllm_path} to {pre_built_vllm_path}") print(f"Linking {current_vllm_path} to {pre_built_vllm_path}")
os.symlink(current_vllm_path, pre_built_vllm_path) os.symlink(current_vllm_path, pre_built_vllm_path)