[+] update pr34

1. update cli_bootstrap
    to explicitly fetch whl-cache;
This commit is contained in:
Siarhei Siniak 2025-11-08 09:56:53 +03:00
parent 7805bad8e7
commit 1377fdd9ff
3 changed files with 31 additions and 3 deletions

@ -5,7 +5,7 @@ project(
).stdout().strip('\n'),
# 'online.fxreader.uv',
# ['c', 'cpp'],
version: '0.1.5.39',
version: '0.1.5.40',
# default_options: [
# 'cpp_std=c++23',
# # 'prefer_static=true',

@ -315,6 +315,7 @@ def pyproject_load(
@dataclasses.dataclass
class BootstrapSettings:
env_path: pathlib.Path
whl_cache_path: pathlib.Path
python_path: pathlib.Path
base_dir: pathlib.Path
python_version: Optional[str] = dataclasses.field(
@ -351,11 +352,14 @@ class BootstrapSettings:
else:
env_path = base_dir / '.venv'
whl_cache_path = env_path.parent / '.venv-whl-cache'
python_path = env_path / 'bin' / 'python3'
return cls(
base_dir=base_dir,
env_path=env_path,
whl_cache_path=whl_cache_path,
python_path=python_path,
)
@ -505,13 +509,33 @@ def env_bootstrap(
]
)
if not bootstrap_settings.env_path.exists():
subprocess.check_call(
[
'pip',
'download',
'--only-binary=:all:',
*uv_python_version,
*pip_find_links_args,
'-r',
str(requirements_path),
'-d',
str(bootstrap_settings.whl_cache_path),
]
)
cache_find_links_args = (
'-f',
str(bootstrap_settings.whl_cache_path),
)
subprocess.check_call(
[
'uv',
*[o for o in bootstrap_settings.uv_args if not o in ['-U', '--upgrade']],
'venv',
*venv_python_version,
*pip_find_links_args,
*cache_find_links_args,
# '--seed',
str(bootstrap_settings.env_path),
]
@ -523,7 +547,8 @@ def env_bootstrap(
'pip',
'install',
*uv_python_version,
*pip_find_links_args,
*cache_find_links_args,
# *pip_find_links_args,
'-p',
bootstrap_settings.python_path,
'--require-hashes',

BIN
releases/whl/online_fxreader_pr34-0.1.5.40-py3-none-any.whl (Stored with Git LFS) Normal file

Binary file not shown.