From 381adb3dd89ca5c574bd9c07bb7b62ee667643f2 Mon Sep 17 00:00:00 2001 From: Yoanm <4410697+yoanm@users.noreply.github.com> Date: Wed, 3 Sep 2025 13:56:58 +0200 Subject: [PATCH 1/4] [BC] Add sf 7.0 and drop 4.4 --- .github/workflows/reusable-CI-workflow.yml | 27 ++++++++++------------ .github/workflows/supported-versions.json | 2 +- composer.json | 16 ++++++------- 3 files changed, 21 insertions(+), 24 deletions(-) diff --git a/.github/workflows/reusable-CI-workflow.yml b/.github/workflows/reusable-CI-workflow.yml index e2f7f31..316c665 100644 --- a/.github/workflows/reusable-CI-workflow.yml +++ b/.github/workflows/reusable-CI-workflow.yml @@ -63,21 +63,21 @@ jobs: symfony-version: '${{ needs.fetch-supported-versions.outputs.symfony-max }}' # Fix - behat/gherkin => Avoid issue with behat <-> gherkin packages (See https://github.com/Behat/Gherkin/issues/317) pkg-extra-constraints: --with 'behat/gherkin:~4.12.0' - - job-name: Up to date versions - Sf 5.4 case + - job-name: Up to date versions - Sf 6.4 case php-version: '${{ needs.fetch-supported-versions.outputs.php-max }}' - symfony-version: '5.4' + symfony-version: '6.4' # Fix - behat/gherkin => Avoid issue with behat <-> gherkin packages (See https://github.com/Behat/Gherkin/issues/317) - # Fix - symfony/yaml - Avoid issue with Sf YAML 6.4+ and Framework bundle - pkg-extra-constraints: --with 'behat/gherkin:~4.12.0' ${{ ( needs.fetch-supported-versions.outputs.symfony-max == '6.4' ) && '--with "symfony/yaml:~6.4.0"' || '' }} + pkg-extra-constraints: --with 'behat/gherkin:~4.12.0' - job-name: Bare minimum # => Lowest versions allowed by composer config php-version: '${{ needs.fetch-supported-versions.outputs.php-min }}' symfony-version: '${{ needs.fetch-supported-versions.outputs.symfony-min }}' - - job-name: Bare minimum - Sf 5.4 case - php-version: '${{ needs.fetch-supported-versions.outputs.php-min }}' - symfony-version: '5.4' - - job-name: Late PHP migration # => Highest symfony version with lowest php version allowed by composer config + - job-name: Bare minimum - Sf 6.4 case # Fix - Sf 6.4 require php 8.1 minimum ! - php-version: ${{ ( needs.fetch-supported-versions.outputs.symfony-max == '6.4' && needs.fetch-supported-versions.outputs.php-min == '8.0' ) && '8.1' || needs.fetch-supported-versions.outputs.php-min }} + php-version: ${{ ( needs.fetch-supported-versions.outputs.php-min == '8.0' ) && '8.1' || needs.fetch-supported-versions.outputs.php-min }} + symfony-version: '6.4' + - job-name: Late PHP migration # => Highest symfony version with lowest php version allowed by composer config + # Fix - Sf 7.0 require php 8.1 minimum, most of deps require 8.2 ! + php-version: ${{ ( needs.fetch-supported-versions.outputs.symfony-max == '7.0' && needs.fetch-supported-versions.outputs.php-min == '8.0' ) && '8.2' || needs.fetch-supported-versions.outputs.php-min }} symfony-version: '${{ needs.fetch-supported-versions.outputs.symfony-max }}' - job-name: Late Symfony migration # => Lowest symfony version with highest php version allowed by composer config php-version: '${{ needs.fetch-supported-versions.outputs.php-max }}' @@ -256,15 +256,12 @@ jobs: php-version: ${{ needs.fetch-supported-versions.outputs.php-max }} symfony-version: ${{ needs.fetch-supported-versions.outputs.symfony-next }} # Fix - behat/gherkin => Avoid issue with behat <-> gherkin packages (See https://github.com/Behat/Gherkin/issues/317) - # Fix - symfony/framework-bundle - Framework bundle <7.0 require php 8.1 minimum ! - pkg-extra-constraints: behat/gherkin:~4.12.0 ${{ ( needs.fetch-supported-versions.outputs.symfony-next == '7.0' && needs.fetch-supported-versions.outputs.php-max == '8.4' ) && 'symfony/framework-bundle:~7.0.0@dev' || '' }} + pkg-extra-constraints: behat/gherkin:~4.12.0 - job-name: Symfony with lowest supported PHP version - # Fix - Sf 7.0 require php 8.1 minimum, most of deps require 8.2 ! - php-version: ${{ ( needs.fetch-supported-versions.outputs.symfony-next == '7.0' && needs.fetch-supported-versions.outputs.php-min == '8.0' ) && '8.2' || needs.fetch-supported-versions.outputs.php-min }} + php-version: ${{ needs.fetch-supported-versions.outputs.php-min }} symfony-version: ${{ needs.fetch-supported-versions.outputs.symfony-next }} # Fix - behat/gherkin => Avoid issue with behat <-> gherkin packages (See https://github.com/Behat/Gherkin/issues/317) - # Fix - symfony/framework-bundle - Framework bundle <7.0 require php 8.1 minimum ! - pkg-extra-constraints: behat/gherkin:~4.12.0 ${{ ( needs.fetch-supported-versions.outputs.symfony-next == '7.0' && needs.fetch-supported-versions.outputs.php-min == '8.0' ) && 'symfony/framework-bundle:~7.0.0@dev' || '' }} + pkg-extra-constraints: behat/gherkin:~4.12.0 steps: - name: Check out code diff --git a/.github/workflows/supported-versions.json b/.github/workflows/supported-versions.json index 9a11141..fefdd3a 100644 --- a/.github/workflows/supported-versions.json +++ b/.github/workflows/supported-versions.json @@ -1,4 +1,4 @@ { "php": {"min": "8.0", "max": "8.4", "next": "8.5"}, - "symfony": {"min": "4.4", "max": "6.4", "next": "7.0"} + "symfony": {"min": "5.4", "max": "7.0", "next": "7.1"} } diff --git a/composer.json b/composer.json index 1f8bb0d..c146105 100644 --- a/composer.json +++ b/composer.json @@ -32,12 +32,12 @@ "require": { "php": "^8.0", "psr/container": "^1.0", - "symfony/config": "^4.4 || ^5.4 || ^6.0", - "symfony/dependency-injection": "^4.4 || ^5.4 || ^6.0", - "symfony/event-dispatcher": "^4.4 || ^5.4 || ^6.0", - "symfony/event-dispatcher-contracts": "^1.0 || ^2.0 || ^3.0", - "symfony/http-foundation": "^4.4 || ^5.4 || ^6.0", - "symfony/http-kernel": "^4.4 || ^5.4 || ^6.0", + "symfony/config": "^5.4 || ^6.4 || ^7.0", + "symfony/dependency-injection": "^5.4 || ^6.4 || ^7.0", + "symfony/event-dispatcher": "^5.4 || ^6.4 || ^7.0", + "symfony/event-dispatcher-contracts": "^2.0 || ^3.0", + "symfony/http-foundation": "^5.4 || ^6.4 || ^7.0", + "symfony/http-kernel": "^5.4 || ^6.4 || ^7.0", "yoanm/jsonrpc-server-sdk": "^3.3" }, "require-dev": { @@ -50,8 +50,8 @@ "phpunit/php-code-coverage": "^9.2.4", "phpunit/phpunit": "^9.0", "squizlabs/php_codesniffer": "^3.5", - "symfony/framework-bundle": "^4.4 || ^5.4 || ^6.0", - "symfony/routing": "^4.4 || ^5.4 || ^6.0", + "symfony/framework-bundle": "^5.4 || ^6.0 || ^7.0", + "symfony/routing": "^5.4 || ^6.0 || ^7.0", "yoanm/php-unit-extended": "^2.0" }, "config": { From f106a65348e6441583d2683c0a291b14feeadb3c Mon Sep 17 00:00:00 2001 From: Yoanm <4410697+yoanm@users.noreply.github.com> Date: Wed, 3 Sep 2025 14:25:33 +0200 Subject: [PATCH 2/4] Fix --- .github/workflows/reusable-CI-workflow.yml | 3 ++- src/DependencyInjection/Configuration.php | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/reusable-CI-workflow.yml b/.github/workflows/reusable-CI-workflow.yml index 316c665..544a257 100644 --- a/.github/workflows/reusable-CI-workflow.yml +++ b/.github/workflows/reusable-CI-workflow.yml @@ -83,7 +83,8 @@ jobs: php-version: '${{ needs.fetch-supported-versions.outputs.php-max }}' symfony-version: '${{ needs.fetch-supported-versions.outputs.symfony-min }}' # Fix - behat/gherkin => Avoid issue with behat <-> gherkin packages (See https://github.com/Behat/Gherkin/issues/317) - pkg-extra-constraints: --with 'behat/gherkin:~4.12.0' + # Fix - symfony/yaml => Avoid issue between symfony/yaml and symfony/framework-bundle (not compatible with some versions due to incomplete function signatures) + pkg-extra-constraints: --with 'behat/gherkin:~4.12.0' ${{ ( needs.fetch-supported-versions.outputs.symfony-min == '5.4' && needs.fetch-supported-versions.outputs.php-max == '8.4' ) && '--with "symfony/yaml:~6.4.0"' || '' }} steps: - name: Check out code uses: actions/checkout@v5 diff --git a/src/DependencyInjection/Configuration.php b/src/DependencyInjection/Configuration.php index 5bf6c1a..3ec14e4 100644 --- a/src/DependencyInjection/Configuration.php +++ b/src/DependencyInjection/Configuration.php @@ -8,7 +8,7 @@ class Configuration implements ConfigurationInterface { const DEFAULT_ENDPOINT = '/json-rpc'; - public function getConfigTreeBuilder() + public function getConfigTreeBuilder(): TreeBuilder { $treeBuilder = new TreeBuilder(JsonRpcHttpServerExtension::EXTENSION_IDENTIFIER); From 32e1da94edbfc0230ea7492810f2e1b5469cda21 Mon Sep 17 00:00:00 2001 From: Yoanm <4410697+yoanm@users.noreply.github.com> Date: Wed, 3 Sep 2025 14:42:24 +0200 Subject: [PATCH 3/4] Fix nightly --- .github/workflows/reusable-CI-workflow.yml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/.github/workflows/reusable-CI-workflow.yml b/.github/workflows/reusable-CI-workflow.yml index 544a257..4d8720b 100644 --- a/.github/workflows/reusable-CI-workflow.yml +++ b/.github/workflows/reusable-CI-workflow.yml @@ -252,14 +252,16 @@ jobs: php-version: ${{ needs.fetch-supported-versions.outputs.php-next }} symfony-version: ${{ needs.fetch-supported-versions.outputs.symfony-min }} # Fix - behat/gherkin => Avoid issue with behat <-> gherkin packages (See https://github.com/Behat/Gherkin/issues/317) - pkg-extra-constraints: behat/gherkin:~4.12.0 + # Fix - symfony/yaml => Avoid issue between symfony/yaml and symfony/framework-bundle (not compatible with some versions due to incomplete function signatures) + pkg-extra-constraints: behat/gherkin:~4.12.0 ${{ ( needs.fetch-supported-versions.outputs.symfony-min == '5.4' && needs.fetch-supported-versions.outputs.php-next == '8.5' ) && 'symfony/yaml:~6.4.0' || '' }} - job-name: Symfony with highest supported PHP version php-version: ${{ needs.fetch-supported-versions.outputs.php-max }} symfony-version: ${{ needs.fetch-supported-versions.outputs.symfony-next }} # Fix - behat/gherkin => Avoid issue with behat <-> gherkin packages (See https://github.com/Behat/Gherkin/issues/317) pkg-extra-constraints: behat/gherkin:~4.12.0 - job-name: Symfony with lowest supported PHP version - php-version: ${{ needs.fetch-supported-versions.outputs.php-min }} + # Fix - Sf 7.1 require php 8.2 minimum ! + php-version: ${{ ( needs.fetch-supported-versions.outputs.symfony-next == '7.1' && needs.fetch-supported-versions.outputs.php-min == '8.0' ) && '8.2' || needs.fetch-supported-versions.outputs.php-min }} symfony-version: ${{ needs.fetch-supported-versions.outputs.symfony-next }} # Fix - behat/gherkin => Avoid issue with behat <-> gherkin packages (See https://github.com/Behat/Gherkin/issues/317) pkg-extra-constraints: behat/gherkin:~4.12.0 From 0441a1fa5886d7c1768feb40c38d77301c15765c Mon Sep 17 00:00:00 2001 From: Yoanm <4410697+yoanm@users.noreply.github.com> Date: Wed, 3 Sep 2025 16:26:41 +0200 Subject: [PATCH 4/4] Fix --- composer.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/composer.json b/composer.json index c146105..2c26caa 100644 --- a/composer.json +++ b/composer.json @@ -50,8 +50,8 @@ "phpunit/php-code-coverage": "^9.2.4", "phpunit/phpunit": "^9.0", "squizlabs/php_codesniffer": "^3.5", - "symfony/framework-bundle": "^5.4 || ^6.0 || ^7.0", - "symfony/routing": "^5.4 || ^6.0 || ^7.0", + "symfony/framework-bundle": "^5.4 || ^6.4 || ^7.0", + "symfony/routing": "^5.4 || ^6.4 || ^7.0", "yoanm/php-unit-extended": "^2.0" }, "config": {