Skip to content

Update versions in matrix - #288

Open
aspark21 wants to merge 4 commits into
mainfrom
aspark21-patch-2
Open

Update versions in matrix#288
aspark21 wants to merge 4 commits into
mainfrom
aspark21-patch-2

Conversation

@aspark21

Copy link
Copy Markdown
Collaborator

No description provided.

Copilot AI lite review requested due to automatic review settings June 21, 2026 21:24

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Updates the GitHub Actions CI matrix to run the plugin test suite against newer Moodle branches while standardizing on PHP 8.3 across all jobs.

Changes:

  • Switched CI coverage from MOODLE_405_STABLE-only to include main and MOODLE_502_STABLE.
  • Removed PHP 8.1 and 8.2 jobs; all matrix entries now run on PHP 8.3.
  • Added explicit database: mariadb/pgsql entries for the new main branch runs.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@andrewhancox

Copy link
Copy Markdown
Contributor

Moodle 4.5 officially supports PHP 8.1 so dropping it from CI means we're not aligned to the minimum requirements.... not sure if that's a problem, just wanted to make sure it was a conscious decision.

@aspark21

Copy link
Copy Markdown
Collaborator Author

minimum requirements are meant to be read in conjunction with the relevant EOL policies

PHP8.1 is EOL

https://www.php.net/supported-versions.php

so yes it was a conscious decision

Copilot AI review requested due to automatic review settings August 13, 2026 16:02

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 1 out of 1 changed files in this pull request and generated 2 comments.

Suppressed comments (1)

.github/workflows/moodle-ci.yml:23

  • Same issue as the Postgres service: when matrix.database != 'mariadb' this evaluates to an empty string, leaving the service with no image and potentially breaking workflow parsing/runtime. Use a concrete image (or separate jobs per database) instead of an empty image string.
        image: ${{ matrix.database == 'mariadb' && 'mariadb:11' || '' }}

services:
postgres:
image: postgres:15
image: ${{ matrix.database == 'pgsql' && 'postgres:17' || '' }}
if: ${{ failure() && steps.behat.outcome == 'failure' }}
uses: actions/upload-artifact@v7
with:
name: Behat Faildump (${{ join(matrix.*, ', ') }})
Copilot AI review requested due to automatic review settings August 13, 2026 16:05

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 1 out of 1 changed files in this pull request and generated 1 comment.

Suppressed comments (2)

.github/workflows/moodle-ci.yml:15

  • services.postgres.image resolves to an empty string for non-PostgreSQL matrix entries, which will make the workflow fail when GitHub Actions tries to start the service (invalid/empty Docker image reference). Define a valid image unconditionally (or split into separate jobs per DB type).
      postgres:
        image: ${{ matrix.database == 'pgsql' && 'postgres:17' || '' }}
        env:

.github/workflows/moodle-ci.yml:7

  • The workflow sets permissions to only contents: read, which can prevent later steps (notably actions/upload-artifact) from working because unspecified permissions become none. Add the minimal required permission for artifact upload (typically actions: write).
permissions:
  contents: read

Comment on lines 22 to 24
mariadb:
image: mariadb:10
image: ${{ matrix.database == 'mariadb' && 'mariadb:11' || '' }}
env:
Copilot AI review requested due to automatic review settings August 13, 2026 16:12

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 1 out of 1 changed files in this pull request and generated 1 comment.

Suppressed comments (3)

.github/workflows/moodle-ci.yml:15

  • GitHub Actions service image cannot be an empty string; when matrix.database is not pgsql this expression resolves to '', which will make the workflow invalid or fail when starting services. Services can’t be conditionally omitted this way.
      postgres:
        image: ${{ matrix.database == 'pgsql' && 'postgres:17' || '' }}
        env:

.github/workflows/moodle-ci.yml:24

  • Same issue as postgres: when matrix.database is not mariadb the service image becomes '', which is not a valid container image value for a GitHub Actions service.
      mariadb:
        image: ${{ matrix.database == 'mariadb' && 'mariadb:11' || '' }}
        env:

.github/workflows/moodle-ci.yml:137

  • join(matrix.*, ', ') is not valid in GitHub Actions expressions (there is no matrix.* wildcard). This will cause workflow evaluation to fail when naming the artifact. Use an explicit name composed from the known matrix keys instead.
        with:
          name: Behat Faildump (${{ join(matrix.*, ', ') }})
          path: ${{ github.workspace }}/moodledata/behat_dump

Comment on lines 64 to +67
with:
php-version: ${{ matrix.php }}
extensions: ${{ matrix.extensions }}
ini-values: max_input_vars=5000
ini-values: max_input_vars=5000, opcache.enable_cli=1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants