Summary
After building and installing pegaflow-llm from source into a uv-managed Python 3.12 virtualenv, the Python console script pegaflow-server fails because the bundled pegaflow-server-py binary cannot find libpython3.12.so.1.0.
Environment
- PegaFlow commit:
4353e76ab63289316c5952c501aac6161c8c439d
- PegaFlow version:
0.21.2
- Python: uv-managed CPython
3.12.12
- Virtualenv:
/root/develop/xingming/.venv
- OS: Ubuntu 22.04
- CUDA: 13.0
- Build command:
./scripts/build-wheel.sh --release --no-default-features --features cuda-13
- Wheel:
pegaflow_llm-0.21.2-cp312-cp312-manylinux_2_35_x86_64.whl
Reproduction
source /root/develop/xingming/.venv/bin/activate
python -m pip install --force-reinstall target/wheels/pegaflow_llm-0.21.2-cp312-cp312-manylinux_2_35_x86_64.whl
pegaflow-server --help
Actual behavior
/root/develop/xingming/.venv/lib/python3.12/site-packages/pegaflow/pegaflow-server-py: error while loading shared libraries: libpython3.12.so.1.0: cannot open shared object file: No such file or directory
ldd confirms the missing dependency:
libpython3.12.so.1.0 => not found
The library exists in uv's Python install, but it is not in the dynamic loader path:
python -c 'import sysconfig; print(sysconfig.get_config_var("LIBDIR"))'
# /root/.local/share/uv/python/cpython-3.12.12-linux-x86_64-gnu/lib
Workaround
export LD_LIBRARY_PATH=$(python -c 'import sysconfig; print(sysconfig.get_config_var("LIBDIR"))'):${LD_LIBRARY_PATH:-}
pegaflow-server --help
Expected behavior
pegaflow-server should work after installing the wheel into the active virtualenv, or the wrapper should add the active Python LIBDIR when launching the bundled binary.
Related minor build-script observation
The build itself succeeded, but the end of scripts/build-wheel.sh appears to look for target/wheels/pegaflow-*.whl, while the generated wheel is named pegaflow_llm-0.21.2-...whl. The script printed:
ls: cannot access '/root/develop/xingming/pegaflow/target/wheels/pegaflow-*.whl': No such file or directory
The command still exited successfully, but the final install hint was empty.
Summary
After building and installing
pegaflow-llmfrom source into a uv-managed Python 3.12 virtualenv, the Python console scriptpegaflow-serverfails because the bundledpegaflow-server-pybinary cannot findlibpython3.12.so.1.0.Environment
4353e76ab63289316c5952c501aac6161c8c439d0.21.23.12.12/root/develop/xingming/.venv./scripts/build-wheel.sh --release --no-default-features --features cuda-13pegaflow_llm-0.21.2-cp312-cp312-manylinux_2_35_x86_64.whlReproduction
source /root/develop/xingming/.venv/bin/activate python -m pip install --force-reinstall target/wheels/pegaflow_llm-0.21.2-cp312-cp312-manylinux_2_35_x86_64.whl pegaflow-server --helpActual behavior
lddconfirms the missing dependency:The library exists in uv's Python install, but it is not in the dynamic loader path:
Workaround
Expected behavior
pegaflow-servershould work after installing the wheel into the active virtualenv, or the wrapper should add the active PythonLIBDIRwhen launching the bundled binary.Related minor build-script observation
The build itself succeeded, but the end of
scripts/build-wheel.shappears to look fortarget/wheels/pegaflow-*.whl, while the generated wheel is namedpegaflow_llm-0.21.2-...whl. The script printed:The command still exited successfully, but the final install hint was empty.