-
Notifications
You must be signed in to change notification settings - Fork 33
Update CI workflow to use current versions of PHP and only Symfony versions still under maintenance #38
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
…rsions still under maintenance Squash-merge of FriendsOfBehat#38 Squashed commit of the following: commit 91a118c Author: Matthias Pigulla <mp@webfactory.de> Date: Wed Dec 17 09:35:55 2025 +0100 Update eligible versions of PHPSpec commit d260a41 Author: Matthias Pigulla <mp@webfactory.de> Date: Wed Dec 17 09:29:15 2025 +0100 Avoid using Flex commit 58eb188 Author: Matthias Pigulla <mp@webfactory.de> Date: Wed Dec 17 09:20:16 2025 +0100 Update current PHP and Symfony versions commit b648d7b Author: Christopher Georg <christopher.georg@sr-travel.de> Date: Sat Nov 8 08:40:43 2025 +0100 ci: add tests for PHP > 8.3 commit 67adb9a Author: Christopher Georg <christopher.georg@sr-travel.de> Date: Fri Nov 7 15:41:28 2025 +0100 ci: add tests for PHP > 8.3 commit 3517e91 Author: Christopher Georg <christopher.georg@sr-travel.de> Date: Fri Nov 7 15:40:19 2025 +0100 ci: add tests for PHP > 8.3 commit 4d051fa Author: Christopher Georg <christopher.georg@sr-travel.de> Date: Fri Nov 7 15:39:17 2025 +0100 ci: add tests for PHP > 8.3 commit eedfe24 Author: Christopher Georg <christopher.georg@sr-travel.de> Date: Fri Nov 7 15:36:47 2025 +0100 ci: add tests for PHP > 8.3
…rsions still under maintenance Squash-merge of FriendsOfBehat#38 Squashed commit of the following: commit 91a118c Author: Matthias Pigulla <mp@webfactory.de> Date: Wed Dec 17 09:35:55 2025 +0100 Update eligible versions of PHPSpec commit d260a41 Author: Matthias Pigulla <mp@webfactory.de> Date: Wed Dec 17 09:29:15 2025 +0100 Avoid using Flex commit 58eb188 Author: Matthias Pigulla <mp@webfactory.de> Date: Wed Dec 17 09:20:16 2025 +0100 Update current PHP and Symfony versions commit b648d7b Author: Christopher Georg <christopher.georg@sr-travel.de> Date: Sat Nov 8 08:40:43 2025 +0100 ci: add tests for PHP > 8.3 commit 67adb9a Author: Christopher Georg <christopher.georg@sr-travel.de> Date: Fri Nov 7 15:41:28 2025 +0100 ci: add tests for PHP > 8.3 commit 3517e91 Author: Christopher Georg <christopher.georg@sr-travel.de> Date: Fri Nov 7 15:40:19 2025 +0100 ci: add tests for PHP > 8.3 commit 4d051fa Author: Christopher Georg <christopher.georg@sr-travel.de> Date: Fri Nov 7 15:39:17 2025 +0100 ci: add tests for PHP > 8.3 commit eedfe24 Author: Christopher Georg <christopher.georg@sr-travel.de> Date: Fri Nov 7 15:36:47 2025 +0100 ci: add tests for PHP > 8.3
…rsions still under maintenance Squash-merge of FriendsOfBehat#38 Squashed commit of the following: commit 91a118c Author: Matthias Pigulla <mp@webfactory.de> Date: Wed Dec 17 09:35:55 2025 +0100 Update eligible versions of PHPSpec commit d260a41 Author: Matthias Pigulla <mp@webfactory.de> Date: Wed Dec 17 09:29:15 2025 +0100 Avoid using Flex commit 58eb188 Author: Matthias Pigulla <mp@webfactory.de> Date: Wed Dec 17 09:20:16 2025 +0100 Update current PHP and Symfony versions commit b648d7b Author: Christopher Georg <christopher.georg@sr-travel.de> Date: Sat Nov 8 08:40:43 2025 +0100 ci: add tests for PHP > 8.3 commit 67adb9a Author: Christopher Georg <christopher.georg@sr-travel.de> Date: Fri Nov 7 15:41:28 2025 +0100 ci: add tests for PHP > 8.3 commit 3517e91 Author: Christopher Georg <christopher.georg@sr-travel.de> Date: Fri Nov 7 15:40:19 2025 +0100 ci: add tests for PHP > 8.3 commit 4d051fa Author: Christopher Georg <christopher.georg@sr-travel.de> Date: Fri Nov 7 15:39:17 2025 +0100 ci: add tests for PHP > 8.3 commit eedfe24 Author: Christopher Georg <christopher.georg@sr-travel.de> Date: Fri Nov 7 15:36:47 2025 +0100 ci: add tests for PHP > 8.3
| - '7.4' | ||
| - '8.0' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We do support PHP 7.4. Why have you removed them from the build?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we still want to support it in the next minor release? That would be an opportunity to change it, and PHP 7.4 had its EOL three years ago.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
dropping support for some PHP versions should be done in a dedicated PR as this is a change that deserves dedicated communication. It cannot be hidden in a PR saying "update CI".
| on: | ||
| push: | ||
| pull_request: | ||
| types: [opened, synchronize, edited, reopened] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why this line was removed?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I had the impression that it would trigger action runs unnecessarily, and most (all?) other open source repos I have experience with don't use it either. It will "do the right thing" by default, run the workflows whenever changes are pushed to the branch.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I see.
I'll wait for @stof comments to be addressed before continuing with my review.
| - name: Restore cached dependencies | ||
| uses: actions/cache@v4 | ||
| with: | ||
| path: vendor | ||
| key: composer-${{ runner.os }}-${{ matrix.php-version }}-${{ matrix.symfony-version }}-${{ hashFiles('composer.json') }} | ||
| restore-keys: | | ||
| composer-${{ runner.os }}-${{ matrix.php-version }}-${{ matrix.symfony-version }}- |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
To cache downloaded packages, to make the planet a bit more 🌱?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the question is whether our CI runs often enough to benefit from the caching of downloads (or whether we consume resources to store the cache but then don't benefit from cache hits)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If it helps us to get this PR along, I’ll remove it
| "require-dev": { | ||
| "behat/mink-goutte-driver": "^1.1 || ^2.0", | ||
| "phpspec/phpspec": "^6.0 || ^7.0 || 7.1.x-dev", | ||
| "phpspec/phpspec": "^7.0 || ^8.0", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why the ^6.0 version was removed and 8.1.x-dev version wasn't added?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
My guess was that back at the time this was written and with the PHP versions current back then, it was necessary to run tests with either a 6.x or an unstable 7.1.* version.
As of today (and with the PHP version change above), stable 7.x or 8.x versions work just fine, so why would we want anything else?
| - '7.4' | ||
| - '8.0' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
dropping support for some PHP versions should be done in a dedicated PR as this is a change that deserves dedicated communication. It cannot be hidden in a PR saying "update CI".
| - name: Restore cached dependencies | ||
| uses: actions/cache@v4 | ||
| with: | ||
| path: vendor | ||
| key: composer-${{ runner.os }}-${{ matrix.php-version }}-${{ matrix.symfony-version }}-${{ hashFiles('composer.json') }} | ||
| restore-keys: | | ||
| composer-${{ runner.os }}-${{ matrix.php-version }}-${{ matrix.symfony-version }}- |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the question is whether our CI runs often enough to benefit from the caching of downloads (or whether we consume resources to store the cache but then don't benefit from cache hits)
| - '8.4' | ||
| # PHPSpec does not yet (2025/12) support PHP 8.5 | ||
| # - '8.5' | ||
| symfony-version: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I suggest refactoring the CI setup to have normal job in the matrix with no enforcement of the Symfony version (letting composer resolve them as would be done in normal projects) and then have only specific jobs included to force testing against Symfony LTS versions (if worth it, not sure for that package)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
And I would probably not add jobs for the 4.4 and 5.4 LTS versions.
| composer-${{ runner.os }}-${{ matrix.php-version }}-${{ matrix.symfony-version }}- | ||
| # We currently cannot use Flex to control versions of Symfony and its components, since that would also impose constraints | ||
| # that cannot anymore be fulfilled by Goutte. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Redefining requirements means we don't actually respect the requirements in composer.json, which is bad. We should be using Flex here (maybe removing the goutte-driver dependency conditionally in those jobs, and ensuring that tests that depend on it are properly skipped)
| run: composer require --no-update "symfony/config:${{ matrix.symfony-version }}" "symfony/dependency-injection:${{ matrix.symfony-version }}" | ||
|
|
||
| - name: Install dependencies | ||
| - name: Install dependencies with targeted Symfony version |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would not change the step name here
|
I think it would be much easier if we accept that the workflow is as it is, maybe even with failures for some jobs. Let’s focus on merging what needs to go into 2.x. Then agree on minimum requirements for 3.x, drop stuff and clean up the workflow when we have no outdated dependencies getting in our way. WDYT? |
|
the existing workflow fails, so we need to fix things in 2.x, not in 3.x only. |
|
The Symfony 4.4 workflow fails because it installs Behat 3.15 with Gherkin 4.16. Behat 3.15 made particular assumptions about how files are organized inside the Gherkin package, and that broke due to a file reorg in Gherkin. Behat/Behat@230c0f5 fixed the issue for Behat 3.20 and above, but we cannot get that fix (it's Symfony 5.4+). Seriously, please let's not waste time trying to fix that workflow for Symfony 4.4. Instead, put all the changes we need into the 2.8 release and raise dependencies to Symfony 5.4 or even above and carry on. Agree? |
|
See my previous comment there: #38 (comment) |
|
Please disregard this PR for the time being. Maybe I'll resume here later, maybe I'll close it. |
|
I don't get it. Could you please make a list which combinations of PHP and Symfony you'd like to see tested on 2.x (2.7?), before we possibly raise requirements in 2.8? Like so? https://github.com/mpdude/MinkExtension/pull/3/changes |
No description provided.