From ce9db13c8f4a6a742cca30037740dc99523165d0 Mon Sep 17 00:00:00 2001 From: William Jacoby Date: Mon, 19 Oct 2026 01:10:55 -0500 Subject: [PATCH 1/4] Run the workflows on Ubuntu 24.04 GitHub has retired the ubuntu-18.04 runner image, so these jobs stayed queued and never ran. ubuntu-22.04 is deprecated and ubuntu-latest is moving to Ubuntu 26.04, so the workflows now pin ubuntu-24.04. Co-Authored-By: Claude Opus 5.5 --- .github/workflows/tests.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index e5736fa..be2b831 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -21,7 +21,7 @@ on: jobs: # START Basic Checks Job (EPV, code sniffer, images check, etc.) basic-checks: - runs-on: ubuntu-18.04 + runs-on: ubuntu-24.04 strategy: matrix: include: @@ -89,7 +89,7 @@ jobs: # START MySQL and MariaDB Job mysql-tests: - runs-on: ubuntu-18.04 + runs-on: ubuntu-24.04 strategy: matrix: include: @@ -237,7 +237,7 @@ jobs: # START PostgreSQL Job postgres-tests: - runs-on: ubuntu-18.04 + runs-on: ubuntu-24.04 strategy: matrix: include: @@ -337,7 +337,7 @@ jobs: # START Other Tests Job (SQLite 3 and mssql) other-tests: - runs-on: ubuntu-18.04 + runs-on: ubuntu-24.04 strategy: matrix: include: From cbc229b84e07c1b3e4b1b6a7089f01cffcb2a6d5 Mon Sep 17 00:00:00 2001 From: William Jacoby Date: Mon, 19 Oct 2026 01:23:57 -0500 Subject: [PATCH 2/4] Test PHP 7.4 to 8.2 phpBB 3.3 requires PHP 7.2 or later, and its bundled Composer refuses to run on PHP 7.1, so the PHP 7.1 jobs could never pass. The matrix now covers PHP 7.4 to 8.2, the range phpbbmodders extensions support: every database at PHP 7.4 (MySQL 5.7 with coverage), plus PHP 8.0, 8.1 and 8.2 on MySQL 5.7, which were commented out. The PHP 7.3 job and a second PHP 7.4 MySQL 5.7 job are dropped. Co-Authored-By: Claude Opus 5.5 --- .github/workflows/tests.yml | 52 +++++++++++++++++-------------------- 1 file changed, 24 insertions(+), 28 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index be2b831..225fcb8 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -25,7 +25,7 @@ jobs: strategy: matrix: include: - - php: '7.1' + - php: '7.4' db: "none" NOTESTS: 1 @@ -93,37 +93,33 @@ jobs: strategy: matrix: include: - - php: '7.1' + - php: '7.4' db: "mariadb:10.1" - - php: '7.1' + - php: '7.4' db: "mariadb:10.2" - - php: '7.1' + - php: '7.4' db: "mariadb:10.3" - - php: '7.1' + - php: '7.4' db: "mariadb:10.4" - - php: '7.1' + - php: '7.4' db: "mariadb:10.5" - - php: '7.1' + - php: '7.4' db: "mysql:5.6" db_alias: "MyISAM Tests" MYISAM: 1 - - php: '7.1' + - php: '7.4' db: "mysql:5.6" - - php: '7.1' - db: "mysql:5.7" - - php: '7.2' - db: "mysql:5.7" - COVERAGE: 1 - - php: '7.3' - db: "mysql:5.7" - php: '7.4' db: "mysql:5.7" + COVERAGE: 1 - php: '7.4' db: "mysql:8.0" - # - php: '8.0' - # db: "mysql:5.7" - # - php: '8.1' - # db: "mysql:5.7" + - php: '8.0' + db: "mysql:5.7" + - php: '8.1' + db: "mysql:5.7" + - php: '8.2' + db: "mysql:5.7" name: PHP ${{ matrix.php }} - ${{ matrix.db_alias != '' && matrix.db_alias || matrix.db }} @@ -241,17 +237,17 @@ jobs: strategy: matrix: include: - - php: '7.1' + - php: '7.4' db: "postgres:9.5" - - php: '7.1' + - php: '7.4' db: "postgres:9.6" - - php: '7.1' + - php: '7.4' db: "postgres:10" - - php: '7.1' + - php: '7.4' db: "postgres:11" - - php: '7.1' + - php: '7.4' db: "postgres:12" - - php: '7.1' + - php: '7.4' db: "postgres:13" name: PHP ${{ matrix.php }} - ${{ matrix.db }} @@ -341,12 +337,12 @@ jobs: strategy: matrix: include: - - php: '7.1' + - php: '7.4' db: "sqlite3" - - php: '7.2' + - php: '7.4' db: "mcr.microsoft.com/mssql/server:2017-latest" db_alias: 'MSSQL 2017' - - php: '7.2' + - php: '7.4' db: "mcr.microsoft.com/mssql/server:2019-latest" db_alias: 'MSSQL 2019' From 2eca679c0af9f3aacdcb2504543002c3145f04bb Mon Sep 17 00:00:00 2001 From: William Jacoby Date: Mon, 19 Oct 2026 01:25:44 -0500 Subject: [PATCH 3/4] Require PHP 7.4 The tests now cover PHP 7.4 to 8.2, the range phpbbmodders extensions support, and phpBB 3.3 itself needs PHP 7.2, so the declared PHP 7.1 minimum (composer.json, ext.php's enable check and the README) is raised to 7.4. Co-Authored-By: Claude Opus 5.5 --- README.md | 2 +- composer.json | 2 +- ext.php | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index c28a264..ce98218 100644 --- a/README.md +++ b/README.md @@ -15,7 +15,7 @@ Adds the ability to add users from an Excel spreadsheet or a CSV file. ## Minimum Requirements * phpBB 3.3.0 -* PHP 7.1.3 +* PHP 7.4 ## Install 1. [Download the latest release](https://github.com/david63/bulkuseradd/archive/3.2.zip) and unzip it. diff --git a/composer.json b/composer.json index 7168367..7e57b62 100644 --- a/composer.json +++ b/composer.json @@ -17,7 +17,7 @@ } ], "require": { - "php": ">=7.1.3", + "php": ">=7.4", "composer/installers": "~1.0", "phpoffice/phpspreadsheet": "^1.18" }, diff --git a/ext.php b/ext.php index 7793962..68cebdc 100644 --- a/ext.php +++ b/ext.php @@ -23,7 +23,7 @@ class ext extends base protected $min_version = '3.3.0'; /** @var PHP version */ - protected $php_version = '7.1.3'; + protected $php_version = '7.4.0'; /** @var phpBB check version */ protected $phpbb_version = '3.3.0'; From 76b744ba2dcbb5d6584e2d9824819b808f5bc88d Mon Sep 17 00:00:00 2001 From: William Jacoby Date: Mon, 19 Oct 2026 01:36:13 -0500 Subject: [PATCH 4/4] Drop the database test jobs The extension has no PHPUnit tests, so the MySQL, PostgreSQL, SQLite and MSSQL jobs only checked that phpBB installs, and on PHP 8 they fail because PHPUnit 9 stops when the tests folder is missing. The basic checks job (code sniffer, EPV, image and executable-file checks) stays. Add database jobs back if tests are written. Co-Authored-By: Claude Opus 5.5 --- .github/workflows/tests.yml | 344 ------------------------------------ 1 file changed, 344 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 225fcb8..e271019 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -86,347 +86,3 @@ jobs: run: phpBB/vendor/bin/EPV.php run --dir="phpBB/ext/$EXTNAME/" working-directory: ./phpBB3 # END Basic Checks Job - - # START MySQL and MariaDB Job - mysql-tests: - runs-on: ubuntu-24.04 - strategy: - matrix: - include: - - php: '7.4' - db: "mariadb:10.1" - - php: '7.4' - db: "mariadb:10.2" - - php: '7.4' - db: "mariadb:10.3" - - php: '7.4' - db: "mariadb:10.4" - - php: '7.4' - db: "mariadb:10.5" - - php: '7.4' - db: "mysql:5.6" - db_alias: "MyISAM Tests" - MYISAM: 1 - - php: '7.4' - db: "mysql:5.6" - - php: '7.4' - db: "mysql:5.7" - COVERAGE: 1 - - php: '7.4' - db: "mysql:8.0" - - php: '8.0' - db: "mysql:5.7" - - php: '8.1' - db: "mysql:5.7" - - php: '8.2' - db: "mysql:5.7" - - name: PHP ${{ matrix.php }} - ${{ matrix.db_alias != '' && matrix.db_alias || matrix.db }} - - services: - mysql: - image: ${{ matrix.db }} - env: - MYSQL_ALLOW_EMPTY_PASSWORD: yes - MYSQL_DATABASE: phpbb_tests - ports: - - 3306:3306 - options: >- - --health-cmd="mysqladmin ping" - --health-interval=10s - --health-timeout=5s - --health-retries=3 - - redis: - image: redis - options: >- - --health-cmd "redis-cli ping" - --health-interval 10s - --health-timeout 5s - --health-retries 5 - ports: - - 6379:6379 - - steps: - - name: Checkout phpBB - uses: actions/checkout@v2 - with: - repository: phpbb/phpbb - ref: ${{ env.PHPBB_BRANCH }} - path: phpBB3 - - - name: Checkout extension - uses: actions/checkout@v2 - with: - path: phpBB3/phpBB/ext/${{ env.EXTNAME }} - - - id: database-type - env: - MATRIX_DB: ${{ matrix.db }} - run: | - db=$(echo "${MATRIX_DB%%:*}") - echo "::set-output name=db::$db" - - - name: Setup PHP - if: ${{ matrix.COVERAGE != 1 }} - uses: shivammathur/setup-php@v2 - with: - php-version: ${{ matrix.php }} - extensions: dom, curl, libxml, mbstring, zip, pcntl, pdo, mysqli, sqlite, pdo_sqlite, intl, gd, exif, iconv, sqlsrv, pdo_sqlsrv, ldap - coverage: none - - - name: Setup PHP with Coverage - if: ${{ matrix.COVERAGE == 1 }} - uses: shivammathur/setup-php@v2 - with: - php-version: ${{ matrix.php }} - extensions: dom, curl, libxml, mbstring, zip, pcntl, pdo, mysqli, sqlite, pdo_sqlite, intl, gd, exif, iconv, sqlsrv, pdo_sqlsrv, ldap - coverage: xdebug - - - name: Setup environment for phpBB - env: - DB: ${{steps.database-type.outputs.db}} - PHP_VERSION: ${{ matrix.php }} - NOTESTS: '0' - run: .github/setup-phpbb.sh $DB $PHP_VERSION ${NOTESTS:-0} - working-directory: ./phpBB3 - - - name: Setup database - env: - DB: ${{steps.database-type.outputs.db}} - MYISAM: ${{ matrix.MYISAM != 1 && '0' || '1' }} - run: .github/setup-database.sh $DB $MYISAM - working-directory: ./phpBB3 - - - name: Setup PHPUnit files - env: - DB: ${{steps.database-type.outputs.db}} - COVERAGE: ${{ matrix.COVERAGE != 1 && '0' || '1' }} - run: | - if [ $COVERAGE == '1' ] - then - sed -n '1h;1!H;${;g;s/<\/php>/<\/php>\n\t\n\t\t\n\t\t\t..\/<\/directory>\n\t\t\t\n\t\t\t\t..\/tests\/<\/directory>\n\t\t\t\t..\/language\/<\/directory>\n\t\t\t\t..\/migrations\/<\/directory>\n\t\t\t<\/exclude>\n\t\t<\/whitelist>\n\t<\/filter>/g;p;}' .github/phpunit-$DB-github.xml &> phpBB/ext/$EXTNAME/.github/phpunit-$DB-github.xml - else - mkdir -p phpBB/ext/$EXTNAME/.github && cp .github/phpunit* $_ - fi - working-directory: ./phpBB3 - - - name: Run unit tests - env: - DB: ${{steps.database-type.outputs.db}} - COVERAGE: ${{ matrix.COVERAGE != 1 && '0' || '1' }} - run: | - if [ $COVERAGE == '1' ] - then - phpBB/vendor/bin/phpunit --configuration phpBB/ext/$EXTNAME/.github/phpunit-$DB-github.xml --bootstrap ./tests/bootstrap.php --coverage-clover build/logs/clover.xml - else - phpBB/vendor/bin/phpunit --configuration phpBB/ext/$EXTNAME/.github/phpunit-$DB-github.xml --bootstrap ./tests/bootstrap.php - fi - working-directory: ./phpBB3 - - - name: Send code coverage - if: ${{ matrix.COVERAGE == 1 }} - uses: codecov/codecov-action@v1 - with: - file: ./phpBB3/build/logs/clover.xml - # END MySQL and MariaDB Job - - # START PostgreSQL Job - postgres-tests: - runs-on: ubuntu-24.04 - strategy: - matrix: - include: - - php: '7.4' - db: "postgres:9.5" - - php: '7.4' - db: "postgres:9.6" - - php: '7.4' - db: "postgres:10" - - php: '7.4' - db: "postgres:11" - - php: '7.4' - db: "postgres:12" - - php: '7.4' - db: "postgres:13" - - name: PHP ${{ matrix.php }} - ${{ matrix.db }} - - services: - postgres: - image: ${{ matrix.db != 'postgres:9.5' && matrix.db != 'postgres:9.6' && matrix.db != 'postgres:10' && matrix.db != 'postgres:11' && matrix.db != 'postgres:12' && matrix.db != 'postgres:13' && 'postgres:10' || matrix.db }} - env: - POSTGRES_HOST: localhost - POSTGRES_USER: postgres - POSTGRES_PASSWORD: postgres - ports: - - 5432:5432 - options: >- - -v /var/run/postgresql:/var/run/postgresql - --health-cmd pg_isready - --health-interval 10s - --health-timeout 5s - --health-retries 5 - - redis: - image: redis - options: >- - --health-cmd "redis-cli ping" - --health-interval 10s - --health-timeout 5s - --health-retries 5 - ports: - - 6379:6379 - - steps: - - name: Checkout phpBB - uses: actions/checkout@v2 - with: - repository: phpbb/phpbb - ref: ${{ env.PHPBB_BRANCH }} - path: phpBB3 - - - name: Checkout extension - uses: actions/checkout@v2 - with: - path: phpBB3/phpBB/ext/${{ env.EXTNAME }} - - - id: database-type - env: - MATRIX_DB: ${{ matrix.db }} - run: | - db=$(echo "${MATRIX_DB%%:*}") - echo "::set-output name=db::$db" - - - name: Setup PHP - uses: shivammathur/setup-php@v2 - with: - php-version: ${{ matrix.php }} - extensions: dom, curl, libxml, mbstring, zip, pcntl, pdo, mysqli, sqlite, pdo_sqlite, intl, gd, exif, iconv, sqlsrv, pdo_sqlsrv, ldap - coverage: none - - - name: Setup environment for phpBB - env: - DB: ${{steps.database-type.outputs.db}} - PHP_VERSION: ${{ matrix.php }} - NOTESTS: '0' - run: .github/setup-phpbb.sh $DB $PHP_VERSION ${NOTESTS:-0} - working-directory: ./phpBB3 - - - name: Setup database - env: - DB: ${{steps.database-type.outputs.db}} - MYISAM: '0' - run: .github/setup-database.sh $DB $MYISAM - working-directory: ./phpBB3 - - - name: Setup PHPUnit files - run: mkdir -p phpBB/ext/$EXTNAME/.github && cp .github/phpunit* $_ - working-directory: ./phpBB3 - - - name: Run unit tests - env: - DB: ${{steps.database-type.outputs.db}} - run: phpBB/vendor/bin/phpunit --configuration phpBB/ext/$EXTNAME/.github/phpunit-$DB-github.xml --bootstrap ./tests/bootstrap.php - working-directory: ./phpBB3 - # END PostgreSQL Job - - # START Other Tests Job (SQLite 3 and mssql) - other-tests: - runs-on: ubuntu-24.04 - strategy: - matrix: - include: - - php: '7.4' - db: "sqlite3" - - php: '7.4' - db: "mcr.microsoft.com/mssql/server:2017-latest" - db_alias: 'MSSQL 2017' - - php: '7.4' - db: "mcr.microsoft.com/mssql/server:2019-latest" - db_alias: 'MSSQL 2019' - - name: PHP ${{ matrix.php }} - ${{ matrix.db_alias != '' && matrix.db_alias || matrix.db }} - - services: - mssql: - image: ${{ matrix.db != 'mcr.microsoft.com/mssql/server:2017-latest' && matrix.db != 'mcr.microsoft.com/mssql/server:2019-latest' && 'mcr.microsoft.com/mssql/server:2017-latest' || matrix.db }} - env: - SA_PASSWORD: "Pssw0rd_12" - ACCEPT_EULA: "y" - ports: - - 1433:1433 - options: >- - --health-cmd="/opt/mssql-tools/bin/sqlcmd -S localhost -U sa -P 'Pssw0rd_12' -Q \"Use [master]; CREATE DATABASE [phpbb_tests] COLLATE Latin1_General_CI_AS\" || exit 1" - --health-interval 10s - --health-timeout 5s - --health-retries 5 - --health-start-period 10s - - redis: - image: redis - options: >- - --health-cmd "redis-cli ping" - --health-interval 10s - --health-timeout 5s - --health-retries 5 - ports: - - 6379:6379 - - steps: - - name: Checkout phpBB - uses: actions/checkout@v2 - with: - repository: phpbb/phpbb - ref: ${{ env.PHPBB_BRANCH }} - path: phpBB3 - - - name: Checkout extension - uses: actions/checkout@v2 - with: - path: phpBB3/phpBB/ext/${{ env.EXTNAME }} - - - id: database-type - env: - MATRIX_DB: ${{ matrix.db }} - run: | - if [ $MATRIX_DB == 'mcr.microsoft.com/mssql/server:2017-latest' ] || [ $MATRIX_DB == 'mcr.microsoft.com/mssql/server:2019-latest' ] - then - db='mssql' - else - db=$(echo "${MATRIX_DB%%:*}") - fi - echo "::set-output name=db::$db" - - - name: Setup PHP - uses: shivammathur/setup-php@v2 - with: - php-version: ${{ matrix.php }} - extensions: dom, curl, libxml, mbstring, zip, pcntl, pdo, mysqli, sqlite, pdo_sqlite, intl, gd, exif, iconv, sqlsrv, pdo_sqlsrv, ldap - coverage: none - - - name: Setup environment for phpBB - env: - DB: ${{steps.database-type.outputs.db}} - PHP_VERSION: ${{ matrix.php }} - NOTESTS: '0' - run: .github/setup-phpbb.sh $DB $PHP_VERSION ${NOTESTS:-0} - working-directory: ./phpBB3 - - - name: Setup database - env: - DB: ${{steps.database-type.outputs.db}} - MYISAM: '0' - run: .github/setup-database.sh $DB $MYISAM - working-directory: ./phpBB3 - - - name: Setup PHPUnit files - run: mkdir -p phpBB/ext/$EXTNAME/.github && cp .github/phpunit* $_ - working-directory: ./phpBB3 - - - name: Run unit tests - env: - DB: ${{steps.database-type.outputs.db}} - run: phpBB/vendor/bin/phpunit --configuration phpBB/ext/$EXTNAME/.github/phpunit-$DB-github.xml --bootstrap ./tests/bootstrap.php - working-directory: ./phpBB3 - # END Other Tests Job