From 3fa3f2dd78bc209ea2da8dd797c86d803926d947 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jose=CC=81=20Arturo=20Garci=CC=81a?= Date: Sun, 16 Aug 2026 14:13:12 -0400 Subject: [PATCH] Build package in isolated runner environment --- .gitea/workflows/publish.yml | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/.gitea/workflows/publish.yml b/.gitea/workflows/publish.yml index 60a3b6f..5478722 100644 --- a/.gitea/workflows/publish.yml +++ b/.gitea/workflows/publish.yml @@ -28,7 +28,10 @@ jobs: run: python3 --version - name: Instalar herramientas - run: python3 -m pip install --upgrade "build>=1,<2" "twine>=6,<7" + run: | + python3 -m venv .ci-venv + .ci-venv/bin/python -m pip install --upgrade \ + "build>=1,<2" "twine>=6,<7" - name: Comprobar credenciales env: @@ -39,7 +42,7 @@ jobs: env: PACKAGE_VERSION: 8.0.${{ gitea.run_number }} run: | - python3 - <<'PY' + .ci-venv/bin/python - <<'PY' from pathlib import Path import os, re path = Path('tryton.cfg') @@ -50,14 +53,14 @@ jobs: - name: Construir y validar run: | - python3 -m build - python3 -m twine check dist/* + .ci-venv/bin/python -m build + .ci-venv/bin/python -m twine check dist/* - name: Publicar en Gitea PyPI env: TWINE_USERNAME: unpaismejor TWINE_PASSWORD: ${{ secrets.REGISTRY_PASSWORD }} run: | - python3 -m twine upload --non-interactive \ + .ci-venv/bin/python -m twine upload --non-interactive \ --repository-url https://code.unpaismejor.org.do/api/packages/tryton-do/pypi \ dist/*