From 790a79bd28353513f3215f695aa046967109ea81 Mon Sep 17 00:00:00 2001 From: TheWitness Date: Mon, 23 Nov 2026 09:14:05 -0500 Subject: [PATCH] =?UTF-8?q?ci:=20Use=20stable=20PHP=208.6=20from=20setup-p?= =?UTF-8?q?hp=20instead=20of=20the=20Ond=C5=99ej=20PPA=20workaround?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit PHP 8.6.0 is released and setup-php's main branch installs it as a stable version. Repin setup-php to that commit, drop the PPA toolchain step and its guards, and run 8.6 as a normal matrix leg. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- .github/workflows/plugin-ci-workflow.yml | 53 ++---------------------- 1 file changed, 3 insertions(+), 50 deletions(-) diff --git a/.github/workflows/plugin-ci-workflow.yml b/.github/workflows/plugin-ci-workflow.yml index 0d9b6427..a8cf9de5 100644 --- a/.github/workflows/plugin-ci-workflow.yml +++ b/.github/workflows/plugin-ci-workflow.yml @@ -50,18 +50,9 @@ jobs: strategy: fail-fast: false matrix: - php: ['8.2', '8.3', '8.4', '8.5'] + php: ['8.2', '8.3', '8.4', '8.5', '8.6'] os: [ubuntu-latest] experimental: [false] - include: - # PHP 8.6 runs as a non-blocking (experimental) leg because - # its packages can lag on the runners and in Ondřej Surý's PPA. - # Pinned to Ubuntu 24.04 (Noble): ubuntu-latest is now Ubuntu 26.04 - # (Resolute), which Ondrej Sury's PPA does not yet serve, so the 8.6 - # PPA toolchain install 404s. Noble carries the latest packaged 8.6 RC. - - php: '8.6' - os: ubuntu-24.04 - experimental: true services: mariadb: @@ -99,8 +90,7 @@ jobs: fetch-depth: 0 - name: Install PHP ${{ matrix.php }} - if: matrix.php != '8.6' - uses: shivammathur/setup-php@eb7c497e18156a6bbabfef1d3a82760b9eda3962 # 2.40.0 + uses: shivammathur/setup-php@e8d43d139fbfbe401c32ef3a3a32e14075f20122 # main (PHP 8.6 stable; after 2.40.0) with: php-version: ${{ matrix.php }} tools: composer:2.10.3 @@ -108,41 +98,6 @@ jobs: ini-values: "post_max_size=256M, max_execution_time=60, date.timezone=America/New_York" coverage: xdebug - # PHP 8.6 is still pre-release. shivammathur/setup-php ships a nightly - # 8.6.0-dev build whose bundled extensions are ABI-skewed against their own - # core (undefined symbol: smart_str_ferealloc / _safe_femalloc), so every - # extension fails to load and the CLI install dies. Ondřej Surý's PPA - # provides a coherent 8.6 RC build, so this experimental leg provisions the - # CLI from there instead. - - name: Install PHP 8.6 toolchain from Ondřej Surý's PPA - if: matrix.php == '8.6' - run: | - set -euo pipefail - sudo add-apt-repository -y ppa:ondrej/php - sudo apt-get -o Acquire::Retries=3 update - sudo apt-get -o Acquire::Retries=3 install -y \ - php8.6-cli php8.6-common \ - php8.6-intl php8.6-mysql php8.6-gd php8.6-ldap \ - php8.6-gmp php8.6-xml php8.6-curl php8.6-mbstring \ - php8.6-snmp php8.6-sqlite3 - # Make the Ondřej 8.6 CLI the default `php` so composer and the tests - # run under the same ABI-coherent build. - sudo update-alternatives --install /usr/bin/php php /usr/bin/php8.6 86 - sudo update-alternatives --set php /usr/bin/php8.6 - # Mirror the ini values the other legs receive via setup-php. - printf '%s\n' \ - 'post_max_size=256M' \ - 'max_execution_time=60' \ - 'date.timezone=America/New_York' \ - | sudo tee /etc/php/8.6/cli/conf.d/99-cacti-ci.ini >/dev/null - # setup-php normally provides Composer; it is skipped for this leg, so - # make sure a Composer binary is available for the dependency steps. - if ! command -v composer >/dev/null 2>&1; then - sudo apt-get -o Acquire::Retries=3 install -y composer - fi - php -v - composer --version - - name: Check PHP version run: php -v @@ -261,9 +216,7 @@ jobs: # inside a live Cacti. What is enforceable is that a change covers the # lines it adds. - name: Enforce coverage of changed lines - # PHP 8.6 installs from the Ondřej PPA, which has no matching xdebug - # build yet, so there is no coverage driver on that experimental leg. - if: github.event_name == 'pull_request' && matrix.php != '8.6' + if: github.event_name == 'pull_request' env: BASE_REF: ${{ github.event.pull_request.base.sha }} run: |