Fix build step to use virtual environment for externally managed Python
Some checks failed
package-tests / test-python-packages (map[name:aitbc-agent-sdk path:packages/py/aitbc-agent-sdk python_version:3.13]) (push) Failing after 15s
package-tests / test-python-packages (map[name:aitbc-cli path:. python_version:3.13]) (push) Failing after 16s
package-tests / test-python-packages (map[name:aitbc-crypto path:packages/py/aitbc-crypto python_version:3.13]) (push) Successful in 10s
package-tests / test-python-packages (map[name:aitbc-core path:packages/py/aitbc-core python_version:3.13]) (push) Successful in 12s
package-tests / test-python-packages (map[name:aitbc-sdk path:packages/py/aitbc-sdk python_version:3.13]) (push) Successful in 13s
package-tests / test-javascript-packages (map[name:aitbc-sdk node_version:24 path:packages/js/aitbc-sdk]) (push) Successful in 18s
security-scanning / audit (push) Successful in 10s
package-tests / cross-language-compatibility (push) Has been skipped
package-tests / package-integration-tests (push) Has been skipped

This commit is contained in:
aitbc1
2026-03-28 12:49:52 +01:00
parent 2c286f7f5a
commit f2d7f0fc4f

View File

@@ -571,6 +571,8 @@ jobs:
# For root-level packages (like aitbc-cli), use python build instead of poetry
if [[ "${{ matrix.package.path }}" == "." ]]; then
echo "Building root-level package with python -m build..."
python3 -m venv .build-venv
source .build-venv/bin/activate
python3 -m pip install build -q
python3 -m build
elif [[ -f "pyproject.toml" ]]; then
@@ -581,7 +583,9 @@ jobs:
poetry build
elif [[ -f "setup.py" ]]; then
echo "No pyproject.toml found, using setup.py..."
python3 -m pip install build setuptools wheel -q
python3 -m venv .build-venv
source .build-venv/bin/activate
pip install build setuptools wheel -q
python3 -m build
else
echo "❌ No pyproject.toml or setup.py found"