[LLM] Add dependency file check in setup.py (#8565)

* add package file check
This commit is contained in:
xingyuan li 2023-07-20 14:20:08 +09:00 committed by GitHub
parent 2eeb653c75
commit 7b8d9c1b0d

View file

@ -223,6 +223,13 @@ def setup_package():
for url in lib_urls[platform_name]:
download_libs(url, change_permission=change_permission)
# Check if all package files are ready
for file in package_data[platform_name]:
file_path = os.path.join(libs_dir, os.path.basename(file))
if not os.path.exists(file_path):
print(f'Could not find package dependency file: {file_path}')
raise FileNotFoundError(f'Could not find package dependency file: {file_path}')
all_requires = ['py-cpuinfo']
all_requires += CONVERT_DEP