From 8c731c24b9a4f933b167f6f0e6dba6a185ba839a Mon Sep 17 00:00:00 2001 From: Jakub Recman Date: Thu, 20 Mar 2025 14:37:19 +0100 Subject: [PATCH 1/7] Switch actions org from ecmwf-actions to ecmwf --- .github/workflows/ci.yaml | 2 +- .github/workflows/label-public-pr.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index a1d0869..5423fb5 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -20,7 +20,7 @@ jobs: name: downstream-ci if: ${{ !github.event.pull_request.head.repo.fork && github.event.action != 'labeled' || github.event.label.name == 'approved-for-ci' }} # FIXME: revert to main when ready - uses: ecmwf-actions/downstream-ci/.github/workflows/downstream-ci.yml@add-conflator + uses: ecmwf/downstream-ci/.github/workflows/downstream-ci.yml@add-conflator with: conflator: ecmwf/conflator@${{ github.event.pull_request.head.sha || github.sha }} codecov_upload: true diff --git a/.github/workflows/label-public-pr.yml b/.github/workflows/label-public-pr.yml index 52f3b87..1baa87b 100644 --- a/.github/workflows/label-public-pr.yml +++ b/.github/workflows/label-public-pr.yml @@ -7,4 +7,4 @@ on: jobs: label: - uses: ecmwf-actions/reusable-workflows/.github/workflows/label-pr.yml@v2 \ No newline at end of file + uses: ecmwf/reusable-workflows/.github/workflows/label-pr.yml@v2 \ No newline at end of file From 699fb767811fdd75e3fc20a65c8fe1e37b2d42a4 Mon Sep 17 00:00:00 2001 From: Oisin-M <60450429+Oisin-M@users.noreply.github.com> Date: Tue, 25 Nov 2025 10:19:15 +0000 Subject: [PATCH 2/7] fix: change downstream ci to use main branch --- .github/workflows/ci.yaml | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index a1d0869..5acdfe8 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -19,8 +19,7 @@ jobs: downstream-ci: name: downstream-ci if: ${{ !github.event.pull_request.head.repo.fork && github.event.action != 'labeled' || github.event.label.name == 'approved-for-ci' }} - # FIXME: revert to main when ready - uses: ecmwf-actions/downstream-ci/.github/workflows/downstream-ci.yml@add-conflator + uses: ecmwf-actions/downstream-ci/.github/workflows/downstream-ci.yml@main with: conflator: ecmwf/conflator@${{ github.event.pull_request.head.sha || github.sha }} codecov_upload: true @@ -159,4 +158,4 @@ jobs: PYPI_PASSWORD: ${{ secrets.PYPI_API_TOKEN }} run: | poetry build - poetry publish --username=$PYPI_USERNAME --password=$PYPI_PASSWORD \ No newline at end of file + poetry publish --username=$PYPI_USERNAME --password=$PYPI_PASSWORD From 327067c02ba72ca32aa36c025ea586731738c9f5 Mon Sep 17 00:00:00 2001 From: awarde96 Date: Mon, 1 Dec 2025 10:07:05 +0000 Subject: [PATCH 3/7] Remove pytest dependency and bump version --- pyproject.toml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 4a57ea0..1a11c32 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "conflator" -version = "0.1.7" +version = "0.1.8" description = "Load small app configurations from environment variables, command line arguments and config files, according to a pydantic model." authors = ["James Hawkes "] readme = "README.md" @@ -11,7 +11,6 @@ repository = "https://github.com/ecmwf/conflator/" python = ">3.9" pydantic = ">2.0" rich-argparse = ">1.0" -pytest = ">8.0" pyyaml = ">6.0" From 2247557c414d74f3a88f7f23664c48b8d4e08f9f Mon Sep 17 00:00:00 2001 From: awarde96 Date: Mon, 1 Dec 2025 11:00:50 +0000 Subject: [PATCH 4/7] Remove legacy ci workflows --- .github/workflows/ci.yaml | 112 -------------------------------------- 1 file changed, 112 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 5ec388e..c71c5a9 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -26,119 +26,7 @@ jobs: python_qa: true secrets: inherit - # qa: - # name: qa - # runs-on: ubuntu-20.04 - # steps: - # - name: Checkout Repository - # uses: actions/checkout@v3 - # with: - # repository: ${{ inputs.repository }} - # ref: ${{ inputs.ref }} - - # - name: Setup Python - # uses: actions/setup-python@v4 - # with: - # python-version: ${{ inputs.python_version }} - - # - name: Install Python Dependencies - # run: | - # python -m pip install --upgrade pip - # python -m pip install black==23.1.0 - # python -m pip install flake8 isort - # - name: Check isort - # run: isort --check . - - # - name: Check black - # run: black --check . - - # - name: Check flake8 - # run: flake8 . - # setup: - # name: setup - # runs-on: ubuntu-20.04 - # outputs: - # matrix: ${{ steps.set-matrix.outputs.matrix }} - # inputs: ${{ steps.prepare-inputs.outputs.inputs }} - # inputs-for-ubuntu: ${{ steps.prepare-inputs.outputs.inputs-for-ubuntu }} - # steps: - # - name: Set Matrix - # id: set-matrix - # shell: bash -eux {0} - # run: | - # MATRIX=$(cat << 'EOS' - # name: - # - gnu-11@ubuntu-22.04 - # - clang-14@ubuntu-22.04 - # include: - # - name: gnu-11@ubuntu-22.04 - # os: ubuntu-22.04 - # compiler: gnu-11 - # compiler_cc: gcc-11 - # compiler_cxx: g++-11 - # compiler_fc: gfortran-11 - # - name: clang-14@ubuntu-22.04 - # os: ubuntu-22.04 - # compiler: clang-14 - # compiler_cc: clang-14 - # compiler_cxx: clang++-14 - # compiler_fc: gfortran-11 - # # Xcode compiler requires empty environment variables, so we pass null (~) here - # EOS - # ) - # SKIP_MATRIX_JOBS=$(cat << 'EOS' - # ${{ inputs.skip_matrix_jobs }} - # EOS - # ) - # SELECT_NAME_COND="1 != 1" - # SELECT_INCLUDE_COND="1 != 1" - # for skip_job in $SKIP_MATRIX_JOBS; do SELECT_NAME_COND="$SELECT_NAME_COND or . == \"$skip_job\""; SELECT_INCLUDE_COND="$SELECT_INCLUDE_COND or .name == \"$skip_job\""; done - # echo matrix=$(echo "$MATRIX" | yq eval "del(.name[] | select($SELECT_NAME_COND)) | del(.include[] | select($SELECT_INCLUDE_COND))" --output-format json --indent 0 -) >> $GITHUB_OUTPUT - # - name: Prepare build-package Inputs - # id: prepare-inputs - # shell: bash -eux {0} - # run: | - # echo inputs=$(echo "${{ inputs.build_package_inputs || '{}' }}" | yq eval '.' --output-format json --indent 0 -) >> $GITHUB_OUTPUT - # echo inputs-for-ubuntu=$(echo "${{ inputs.build_package_inputs || '{}' }}" | yq eval '. * {"os":"ubuntu-20.04","compiler":"gnu-10","compiler_cc":"gcc-10","compiler_cxx":"g++-10","compiler_fc":"gfortran-10"}' --output-format json --indent 0 -) >> $GITHUB_OUTPUT - test: - name: test - needs: - # - qa - # - setup - - downstream-ci - strategy: - fail-fast: false - matrix: ${{ fromJson(needs.setup.outputs.matrix) }} - runs-on: ${{ matrix.os }} - steps: - - uses: actions/checkout@v4 - - name: Setup Python - uses: actions/setup-python@v4 - with: - python-version: ${{ inputs.python_version }} - - - name: Install Python Dependencies - run: | - python -m pip install --upgrade pip - pip install --upgrade pip setuptools wheel - python -m pip install pytest pytest-cov - python -m pip install -r requirements.txt - python -m pip install -r ./tests/requirements_test.txt - - - name: Run Tests with Repository Code - env: - LD_LIBRARY_PATH: ${{ steps.install-dependencies.outputs.lib_path }} - shell: bash -eux {0} - run: | - DYLD_LIBRARY_PATH=${{ env.LD_LIBRARY_PATH }} python -m pytest tests --cov=./ --cov-report=xml - python -m coverage report - - - name: Upload coverage to Codecov - uses: codecov/codecov-action@v3 - with: - files: coverage.xml deploy: - needs: test if: ${{ github.event_name == 'release' }} name: Upload to Pypi runs-on: ubuntu-latest From 7043d82953b0126433c328fd6f132a53fec800b4 Mon Sep 17 00:00:00 2001 From: mathleur Date: Mon, 1 Dec 2025 12:13:31 +0100 Subject: [PATCH 5/7] only deps in pyproject --- .github/workflows/tox.yml | 25 ------------------------- pyproject.toml | 1 - requirements.txt | 4 ---- tests/requirements_test.txt | 3 --- 4 files changed, 33 deletions(-) delete mode 100644 .github/workflows/tox.yml delete mode 100644 requirements.txt delete mode 100644 tests/requirements_test.txt diff --git a/.github/workflows/tox.yml b/.github/workflows/tox.yml deleted file mode 100644 index 8d9c967..0000000 --- a/.github/workflows/tox.yml +++ /dev/null @@ -1,25 +0,0 @@ -# name: Test with tox - -# on: -# - push -# - pull_request - -# jobs: -# build: -# runs-on: ubuntu-latest -# strategy: -# matrix: -# python-version: ['3.9', '3.10', '3.11', '3.12'] - -# steps: -# - uses: actions/checkout@v3 -# - name: Set up Python ${{ matrix.python-version }} -# uses: actions/setup-python@v4 -# with: -# python-version: ${{ matrix.python-version }} -# - name: Install dependencies -# run: | -# python -m pip install --upgrade pip -# python -m pip install tox tox-gh-actions -# - name: Test with tox -# run: tox \ No newline at end of file diff --git a/pyproject.toml b/pyproject.toml index 1a11c32..aa9bd17 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -13,7 +13,6 @@ pydantic = ">2.0" rich-argparse = ">1.0" pyyaml = ">6.0" - [tool.poetry.group.dev.dependencies] mypy = ">1.8.0" ruff = ">0.2.0" diff --git a/requirements.txt b/requirements.txt deleted file mode 100644 index 72754b5..0000000 --- a/requirements.txt +++ /dev/null @@ -1,4 +0,0 @@ -pydantic==2.6.0 -pydantic_core==2.16.1 -rich==13.7.0 -rich-argparse==1.4.0 \ No newline at end of file diff --git a/tests/requirements_test.txt b/tests/requirements_test.txt deleted file mode 100644 index 5d26cde..0000000 --- a/tests/requirements_test.txt +++ /dev/null @@ -1,3 +0,0 @@ --r ../requirements.txt -annotated-types==0.6.0 -pytest==8.0.0 \ No newline at end of file From 57778cceb4f0cbf75a07116716b0c77fdac1c6e9 Mon Sep 17 00:00:00 2001 From: oisin-m Date: Thu, 4 Dec 2025 12:23:31 +0000 Subject: [PATCH 6/7] chore: remove unused code --- tox.ini | 21 --------------------- 1 file changed, 21 deletions(-) diff --git a/tox.ini b/tox.ini index d8c58d1..5acee76 100644 --- a/tox.ini +++ b/tox.ini @@ -1,24 +1,3 @@ -[tox] -env_list = py{39,310,311,312} -minversion = 4.12.1 - -[testenv] -description = run the tests with pytest -package = wheel -wheel_build_env = .pkg -deps = - pytest>=6 -commands = - pytest {tty:--color=yes} {posargs} - -# Provide a mapping between tox envs and github actions python envs -[gh-actions] -python = - 3.9: py39 - 3.10: py310 - 3.11: py311 - 3.12: py312 - [flake8] max-line-length = 120 exclude = .* From 875b23150b32cd2ec919f7a87cb0e41738b9b42a Mon Sep 17 00:00:00 2001 From: oisin-m Date: Thu, 4 Dec 2025 12:24:27 +0000 Subject: [PATCH 7/7] fix: pin minimum pydantic version --- pyproject.toml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index aa9bd17..f632e71 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,3 +1,7 @@ +[build-system] +requires = ["poetry-core"] +build-backend = "poetry.core.masonry.api" + [tool.poetry] name = "conflator" version = "0.1.8" @@ -9,7 +13,7 @@ repository = "https://github.com/ecmwf/conflator/" [tool.poetry.dependencies] python = ">3.9" -pydantic = ">2.0" +pydantic = ">=2.9" rich-argparse = ">1.0" pyyaml = ">6.0" @@ -17,10 +21,6 @@ pyyaml = ">6.0" mypy = ">1.8.0" ruff = ">0.2.0" -[build-system] -requires = ["poetry-core"] -build-backend = "poetry.core.masonry.api" - [tool.ruff] line-length = 120 lint.extend-select = ["I"]