Skip to content
Snippets Groups Projects
Commit 956388c4 authored by Ahmed Ilyas's avatar Ahmed Ilyas
Browse files

Merge branch 'one-step-for-package-installs' into 'develop'

Use uv python to run package install tests

See merge request !2425
parents b66daca1 e18d03cb
Branches
Tags
1 merge request!2425Use uv python to run package install tests
Pipeline #255242 passed
......@@ -326,24 +326,29 @@ build python package:
python package install tests:
stage: test
parallel:
matrix:
- PYTHON_VERSION: ["3.10", "3.11", "3.12"]
image: python:${PYTHON_VERSION}
image: ghcr.io/astral-sh/uv:$UV_VERSION-python$PYTHON_VERSION-bookworm
needs: ["build python package"]
variables:
UV_SYSTEM_PYTHON: true
UV_LINK_MODE: copy
GIT_STRATEGY: none
before_script:
- pip install --upgrade pip
- pip install uv==${UV_VERSION}
script:
- pip install dist/nomad-*.tar.gz
- python -c 'import nomad.cli'
- python -c 'from nomad.client import ArchiveQuery'
- python -m nomad.cli parse --skip-normalizers archive.json
- uv pip install git+https://github.com/nomad-coe/nomad-parser-example.git@ba6027fdd4cda0cf9e0b32546bd809c8fdda79e6
- python -m exampleparser example.out
- |
for PYTHON_VERSION in 3.10 3.11 3.12; do
echo "Running for Python $PYTHON_VERSION"
uv venv -p $PYTHON_VERSION
uv pip install dist/nomad-*.tar.gz
./.venv/bin/python -c 'import nomad.cli'
./.venv/bin/python -c 'from nomad.client import ArchiveQuery'
./.venv/bin/python -m nomad.cli parse --skip-normalizers archive.json
uv pip install git+https://github.com/nomad-coe/nomad-parser-example.git@ba6027fdd4cda0cf9e0b32546bd809c8fdda79e6
./.venv/bin/python -m exampleparser example.out
echo "\n"
done
rules:
- if: $CI_PIPELINE_SOURCE == "schedule" || $CI_COMMIT_TAG
- <<: *non-docs-changes
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment