Skip to content

Commit bf452bd

Browse files
committed
Update CI
1 parent e735081 commit bf452bd

19 files changed

Lines changed: 72 additions & 84 deletions

‎.ci/ansible/inventory.yaml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ all:
55
hosts:
66
pulp:
77
pulp-fixtures:
8-
minio:
8+
rustfs:
99
ci-sftp:
1010
vars:
1111
ansible_connection: docker

‎.ci/ansible/start_container.yaml‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -64,9 +64,9 @@
6464
from botocore.exceptions import ClientError
6565
client = boto3.client(
6666
"s3",
67-
aws_access_key_id="{{ minio_access_key }}",
68-
aws_secret_access_key="{{ minio_secret_key }}",
69-
endpoint_url="http://minio:9000",
67+
aws_access_key_id="{{ rustfs_access_key }}",
68+
aws_secret_access_key="{{ rustfs_secret_key }}",
69+
endpoint_url="http://rustfs:9000",
7070
region_name="eu-central-1",
7171
)
7272
try:

‎.ci/assets/ci_constraints.txt‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Pulpcore versions without the openapi command do no longer work in the CI
22
# Pulpcore versions without the django 5 storage compatibility will fail, >3.63,<3.70
3-
pulpcore>=3.21.30,!=3.23.*,!=3.24.*,!=3.25.*,!=3.26.*,!=3.27.*,!=3.29.*,!=3.30.*,!=3.31.*,!=3.32.*,!=3.33.*,!=3.34.*,!=3.35.*,!=3.36.*,!=3.37.*,!=3.38.*,!=3.40.*,!=3.41.*,!=3.42.*,!=3.43.*,!=3.44.*,!=3.45.*,!=3.46.*,!=3.47.*,!=3.48.*,!=3.50.*,!=3.51.*,!=3.52.*,!=3.53.*,!=3.54.*,!=3.64.*,!=3.65.*,!=3.66.*,!=3.67.*,!=3.68.*,!=3.69.*
3+
pulpcore>=3.49.0,!=3.50.*,!=3.51.*,!=3.52.*,!=3.53.*,!=3.54.*,!=3.64.*,!=3.65.*,!=3.66.*,!=3.67.*,!=3.68.*,!=3.69.*
44

55

66
tablib!=3.6.0

‎.ci/scripts/calc_constraints.py‎

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,10 +26,14 @@
2626
def fetch_pulpcore_upper_bound(requirement):
2727
with urllib.request.urlopen(CORE_TEMPLATE_URL) as f:
2828
template = yaml.safe_load(f.read())
29-
supported_versions = template["supported_release_branches"]
30-
supported_versions.append(template["latest_release_branch"])
29+
supported_branches = [
30+
*template["supported_release_branches"],
31+
template["latest_release_branch"],
32+
]
3133
applicable_versions = sorted(
32-
requirement.specifier.filter((Version(v) for v in supported_versions))
34+
Version(branch)
35+
for branch in supported_branches
36+
if requirement.specifier.contains(Version(f"{branch}.999999"))
3337
)
3438
if len(applicable_versions) == 0:
3539
raise Exception("No supported pulpcore version in required range.")

‎.ci/scripts/pr_labels.py‎

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,10 @@
11
#!/bin/env python3
2+
# /// script
3+
# requires-python = ">=3.12"
4+
# dependencies = [
5+
# "gitpython>=3.1.62",
6+
# ]
7+
# ///
28

39
# This script is running with elevated privileges from the main branch against pull requests.
410

‎.ci/scripts/skip_tests.py‎

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,10 @@
11
#!/usr/bin/env python3
2+
# /// script
3+
# requires-python = ">=3.12"
4+
# dependencies = [
5+
# "gitpython>=3.1.62",
6+
# ]
7+
# ///
28
"""
39
skip_tests.py - Check if only documentation files were changed in a git branch
410

‎.ci/scripts/validate_commit_message.py‎

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,14 @@
11
# This file is managed by the plugin template.
22
# Do not edit.
33

4+
# /// script
5+
# requires-python = ">=3.12"
6+
# dependencies = [
7+
# "pygithub",
8+
# "pyyaml",
9+
# ]
10+
# ///
11+
412
import os
513
import re
614
import subprocess

‎.github/workflows/build.yml‎

Lines changed: 3 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -38,15 +38,13 @@ jobs:
3838
uses: "astral-sh/setup-uv@v7"
3939
with:
4040
enable-cache: true
41-
- name: "Install python dependencies"
42-
run: |
43-
uv pip install build packaging twine wheel mkdocs jq
4441
- name: "Build package"
4542
run: |
46-
python3 -m build
47-
twine check dist/*
43+
uv build
44+
uvx twine check dist/*
4845
- name: "Install built packages"
4946
run: |
47+
# This seems to be the only way to inject the constraints file.
5048
uv pip install dist/pulp_python-*-py3-none-any.whl -c .ci/assets/ci_constraints.txt
5149
- name: "Generate api specs"
5250
run: |
@@ -88,15 +86,6 @@ jobs:
8886
if-no-files-found: "error"
8987
retention-days: 5
9088
overwrite: true
91-
- name: "Upload python client docs"
92-
uses: "actions/upload-artifact@v7"
93-
with:
94-
name: "python-client-docs.tar"
95-
path: |
96-
pulp_python/python-python-client-docs.tar
97-
if-no-files-found: "error"
98-
retention-days: 5
99-
overwrite: true
10089
- name: "Build Ruby bindings packages"
10190
run: |
10291
.github/workflows/scripts/build_ruby_client.sh

‎.github/workflows/ci.yml‎

Lines changed: 3 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -30,16 +30,12 @@ jobs:
3030
path: "pulp_python"
3131
- uses: "actions/setup-python@v6"
3232
with:
33-
python-version: "3.11"
33+
python-version: "3.12"
3434
- name: "Install uv"
3535
uses: "astral-sh/setup-uv@v7"
3636
with:
3737
enable-cache: true
38-
- name: "Install python dependencies"
39-
run: |
40-
uv pip install requests pygithub pyyaml
4138
- name: "Check commit message"
42-
if: github.event_name == 'pull_request'
4339
env:
4440
PY_COLORS: "1"
4541
ANSIBLE_FORCE_COLOR: "1"
@@ -61,16 +57,12 @@ jobs:
6157

6258
- uses: "actions/setup-python@v6"
6359
with:
64-
python-version: "3.11"
60+
python-version: "3.12"
6561
- name: "Install uv"
6662
uses: "astral-sh/setup-uv@v7"
6763
with:
6864
enable-cache: true
6965

70-
- name: "Install python dependencies"
71-
run: |
72-
uv pip install gitpython
73-
7466
- name: "Analyze changed files"
7567
id: "check"
7668
shell: "bash"
@@ -86,7 +78,7 @@ jobs:
8678
BASE_REF=${{ github.event.pull_request.base.sha }}
8779
echo "Checking against:"
8880
git name-rev $BASE_REF
89-
python3 .ci/scripts/skip_tests.py . $BASE_REF
81+
uv run --script .ci/scripts/skip_tests.py . $BASE_REF
9082
exit_code=$?
9183
if [ $exit_code -ne 0 ] && [ $exit_code -ne 1 ]; then
9284
echo "Error: skip_tests.py returned unexpected exit code $exit_code"

‎.github/workflows/pr_checks.yml‎

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -40,16 +40,15 @@ jobs:
4040
fetch-depth: 0
4141
- uses: "actions/setup-python@v6"
4242
with:
43-
python-version: "3.11"
43+
python-version: "3.14"
4444
- name: "Install uv"
4545
uses: "astral-sh/setup-uv@v7"
4646
with:
4747
enable-cache: true
4848
- name: "Determine PR labels"
4949
run: |
50-
uv pip install GitPython==3.1.42
5150
git fetch origin ${{ github.event.pull_request.head.sha }}
52-
python .ci/scripts/pr_labels.py "origin/${{ github.base_ref }}" "${{ github.event.pull_request.head.sha }}" >> "$GITHUB_ENV"
51+
uv run --script .ci/scripts/pr_labels.py "origin/${{ github.base_ref }}" "${{ github.event.pull_request.head.sha }}" >> "$GITHUB_ENV"
5352
- uses: "actions/github-script@v8"
5453
name: "Apply PR Labels"
5554
with:

0 commit comments

Comments
 (0)