From 62ce9311bfb926411e9a59c839952dd2b1902821 Mon Sep 17 00:00:00 2001 From: Alejandro Celaya Date: Sat, 24 Sep 2022 08:03:38 +0200 Subject: [PATCH 1/4] Added PHP 8.2 to build matrixes --- .github/actions/ci-setup/action.yml | 5 ++++- .github/workflows/ci-db-tests.yml | 3 ++- .github/workflows/ci-mutation-tests.yml | 3 ++- .github/workflows/ci-tests.yml | 3 ++- .github/workflows/ci.yml | 3 ++- 5 files changed, 12 insertions(+), 5 deletions(-) diff --git a/.github/actions/ci-setup/action.yml b/.github/actions/ci-setup/action.yml index 78cbdf1c..f153b259 100644 --- a/.github/actions/ci-setup/action.yml +++ b/.github/actions/ci-setup/action.yml @@ -41,7 +41,10 @@ runs: extensions: ${{ inputs.php-extensions }} coverage: pcov ini-values: pcov.directory=module + - run: echo "::set-output name=composerArgs::${{ inputs.php-version == '8.2' && '--ignore-platform-req-php' || '' }}" + id: composer_args + shell: bash - name: Install dependencies if: ${{ inputs.install-deps == 'yes' }} - run: composer install --no-interaction --prefer-dist + run: composer install --no-interaction --prefer-dist ${{ steps.composer_args.outputs.composerArgs }} shell: bash diff --git a/.github/workflows/ci-db-tests.yml b/.github/workflows/ci-db-tests.yml index 09543610..50060383 100644 --- a/.github/workflows/ci-db-tests.yml +++ b/.github/workflows/ci-db-tests.yml @@ -13,7 +13,8 @@ jobs: runs-on: ubuntu-22.04 strategy: matrix: - php-version: [ '8.1' ] + php-version: ['8.1', '8.2'] + continue-on-error: ${{ matrix.php-version == '8.2' }} env: LC_ALL: C steps: diff --git a/.github/workflows/ci-mutation-tests.yml b/.github/workflows/ci-mutation-tests.yml index 7a9dd751..c7b361d8 100644 --- a/.github/workflows/ci-mutation-tests.yml +++ b/.github/workflows/ci-mutation-tests.yml @@ -13,7 +13,8 @@ jobs: runs-on: ubuntu-22.04 strategy: matrix: - php-version: [ '8.1' ] + php-version: ['8.1', '8.2'] + continue-on-error: ${{ matrix.php-version == '8.2' }} steps: - uses: actions/checkout@v3 - uses: './.github/actions/ci-setup' diff --git a/.github/workflows/ci-tests.yml b/.github/workflows/ci-tests.yml index b7f7af98..e20428c6 100644 --- a/.github/workflows/ci-tests.yml +++ b/.github/workflows/ci-tests.yml @@ -13,7 +13,8 @@ jobs: runs-on: ubuntu-22.04 strategy: matrix: - php-version: ['8.1'] + php-version: ['8.1', '8.2'] + continue-on-error: ${{ matrix.php-version == '8.2' }} steps: - uses: actions/checkout@v3 - name: Start postgres database server diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index f9d3660e..a12cee65 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -43,7 +43,8 @@ jobs: runs-on: ubuntu-22.04 strategy: matrix: - php-version: [ '8.1' ] + php-version: ['8.1', '8.2'] + continue-on-error: ${{ matrix.php-version == '8.2' }} steps: - uses: actions/checkout@v3 - run: docker-compose -f docker-compose.yml -f docker-compose.ci.yml up -d shlink_db_postgres From 0871ca884ed1130f34900e1c18d10fd185ba41db Mon Sep 17 00:00:00 2001 From: Alejandro Celaya Date: Sat, 24 Sep 2022 08:06:41 +0200 Subject: [PATCH 2/4] Fixed typo --- .github/actions/ci-setup/action.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/actions/ci-setup/action.yml b/.github/actions/ci-setup/action.yml index f153b259..0a8a09d7 100644 --- a/.github/actions/ci-setup/action.yml +++ b/.github/actions/ci-setup/action.yml @@ -41,7 +41,7 @@ runs: extensions: ${{ inputs.php-extensions }} coverage: pcov ini-values: pcov.directory=module - - run: echo "::set-output name=composerArgs::${{ inputs.php-version == '8.2' && '--ignore-platform-req-php' || '' }}" + - run: echo "::set-output name=composerArgs::${{ inputs.php-version == '8.2' && '--ignore-platform-req=php' || '' }}" id: composer_args shell: bash - name: Install dependencies From e5107c40f92da6748698fc1e82755d2998c631ec Mon Sep 17 00:00:00 2001 From: Alejandro Celaya Date: Sat, 24 Sep 2022 08:14:52 +0200 Subject: [PATCH 3/4] Ignored platform req during roadrunner API tests in CI workflow when using PHP 8.2 --- .github/workflows/ci.yml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index a12cee65..48867481 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -52,7 +52,10 @@ jobs: with: php-version: ${{ matrix.php-version }} tools: composer - - run: composer install --no-interaction --prefer-dist + - run: echo "::set-output name=composerArgs::${{ inputs.php-version == '8.2' && '--ignore-platform-req=php' || '' }}" + id: composer_args + shell: bash + - run: composer install --no-interaction --prefer-dist ${{ steps.composer_args.outputs.composerArgs }} - run: ./vendor/bin/rr get --no-interaction --location bin/ && chmod +x bin/rr - run: composer test:api:rr From 3f808e38139048b0ed77e735391b43b6830517e7 Mon Sep 17 00:00:00 2001 From: Alejandro Celaya Date: Sat, 24 Sep 2022 08:17:14 +0200 Subject: [PATCH 4/4] Updated changelog --- .github/workflows/ci.yml | 2 +- CHANGELOG.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 48867481..013226a6 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -52,7 +52,7 @@ jobs: with: php-version: ${{ matrix.php-version }} tools: composer - - run: echo "::set-output name=composerArgs::${{ inputs.php-version == '8.2' && '--ignore-platform-req=php' || '' }}" + - run: echo "::set-output name=composerArgs::${{ matrix.php-version == '8.2' && '--ignore-platform-req=php' || '' }}" id: composer_args shell: bash - run: composer install --no-interaction --prefer-dist ${{ steps.composer_args.outputs.composerArgs }} diff --git a/CHANGELOG.md b/CHANGELOG.md index 5bd2a518..5cf0ba28 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,7 +6,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com), and this ## [Unreleased] ### Added -* *Nothing* +* [#1474](https://github.com/shlinkio/shlink/issues/1474) Added preliminary support for PHP 8.2 during CI workflow. ### Changed * [#1551](https://github.com/shlinkio/shlink/issues/1551) Moved services related to geolocating visits to the `Visit\Geolocation` namespace.