diff --git a/.ci/scripts/calc_constraints.py b/.ci/scripts/calc_constraints.py index b9af2e73f9..a9e4910312 100755 --- a/.ci/scripts/calc_constraints.py +++ b/.ci/scripts/calc_constraints.py @@ -4,6 +4,15 @@ # './plugin-template --github pulpcore' to update this file. # # For more info visit https://github.com/pulp/plugin_template +#!/usr/bin/env python +# /// script +# requires-python = ">=3.9" +# dependencies = [ +# "packaging>=26.0,<27", +# "pyyaml>=6.0.3,<6.1", +# "tomli;python_version<'3.11'", +# ] +# /// import argparse import fileinput diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index e6444d6727..e41fd93edf 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -44,8 +44,9 @@ jobs: uvx twine check dist/* - name: "Install built packages" run: | + uv run --script .ci/scripts/calc_constraints.py -u requirements.txt > upperbounds_constraints.txt # This seems to be the only way to inject the constraints file. - uv pip install dist/pulpcore-*-py3-none-any.whl -c .ci/assets/ci_constraints.txt + uv pip install dist/pulpcore-*-py3-none-any.whl -c .ci/assets/ci_constraints.txt -c upperbounds_constraints.txt - name: "Generate api specs" run: | pulpcore-manager openapi --file "api.json"