quantum-php-project icon indicating copy to clipboard operation
quantum-php-project copied to clipboard

Raise the minimum PHP version to 8.2 and update the dependencies

Open armanist opened this issue 2 weeks ago • 0 comments

Summary

Bring the starter project in line with framework 3.2.0 (quantum-php/framework#687): require PHP 8.2 and move every Composer dependency to its newest version that runs on PHP 8.2.

Why

  • Framework 3.2.0 requires PHP 8.2 and Symfony 7.4. The project as it is cannot install it: its symfony/process and symfony/yaml ^5.4 conflict with symfony/console 7.4, which needs symfony/process 6.4 or newer.
  • PHPUnit 9 is no longer maintained.

Scope

One checkpoint per item, each one commit:

  1. PHP 8.2: composer.json "php": "^8.2"; CI matrix 8.2, 8.3 and 8.4 (8.1 is dropped); .scrutinizer.yml PHP 8.2; PHPStan phpVersion 80200; Rector LevelSetList::UP_TO_PHP_82; the requirement in README.md ("PHP 8.2 or newer").
  2. Symfony 7.4: symfony/process and symfony/yaml ^5.4 to ^7.4 (the LTS line the framework uses; 8.x needs PHP 8.4).
  3. Tests: dev phpunit/phpunit ^9.0 to ^11.5 (12 needs PHP 8.3), with phpunit.xml and the tests' doc-comment markers moved to attributes; mockery/mockery ^1.2 to ^1.6.
  4. The framework constraint: quantum/framework ^3.1.2 to 3.2.*@dev until 3.2.0 is released, then ^3.2.0 in the release PR.
  5. Everything else is checked and stays: fakerphp/faker, bluemmb/faker-picsum-photos-provider and ottaviano/faker-gravatar have no newer major; friendsofphp/php-cs-fixer, rector/rector and phpstan/phpstan are current within their constraints.

Order

This comes after quantum-php/framework#687 is merged into 3.2.x, because the project needs that code to install.

Breaking changes

  • PHP 8.1 can no longer install the project. Applications on 8.1 stay on 3.1.x.
  • An application created from the project that uses symfony/process or symfony/yaml directly gets their 7.4 versions.

armanist avatar Nov 20 '26 20:11 armanist