Open Eduardo-Morales-Alberti opened 1 year ago
Your proposed change would instead conflict with D10: https://github.com/drupal/core-dev/blob/10.0.x/composer.json.
Do you really need drupal/core-dev? Are you running phpunit browser tests in the same environment? If not, you could drop the core-dev dependency and only require what you actually need.
Hmm, it is fairly common I think to run phpunit tests (based on core's base classes) in the same environments as Behat, so ideally we'd fix this conflict with drupal/core-dev
...
We could be compatible with two different versions of the same package, but we're talking about two different packages here, I don't think that's possible.
You can still explicitly require phpunit and other dependencies, just not the drupal/core-dev wrapper.
I think friends-of-behat/mink-browserkit-driver was forked to be compatible with PHP 8 and higher versions of Symfony, it could be deprecated, and should be changed on core-dev. Maybe this is not the place.
Created PR on core-dev https://github.com/drupal/core-dev/pull/4/files, sorry for the noise.
It looks like from the comment on that PR you'll need to open an issue on drupal.org since the github repo is auto-generated.
Core isn't going to change this, it will not introduce possibly breaking changes in Drupal 9. The main point of drupal/core-dev is to be able to reliable run the same phpunit tests that core (and contrib) contains.
If you can't update to D10 yet then the only option is to not require drupal/core-dev but rely on the desired dependencies and versions directly. Might be worth mentioning this in the readme/release notes of 5.x
If the friends-of-behat
one is truly deprecated, wouldn't core update to the non-deprecated one? I'm having trouble finding documentation about the deprecations or preferred package though. This https://github.com/minkphp/MinkBrowserKitDriver seems more active than the friends one...
if the friends-of-behat one is truly deprecated, wouldn't core update to the non-deprecated one?
That's exactly what core did, but only in D10, as it was apparently considered a BC breaking change or maybe just not important enough. I wasn't involved in the issue and don't know the exact reason. But I can guarantee you that this will not be changed in a 9.5 patch release, so we just have to live with it.
ah, ok, I misunderstood.
Created issue on core https://www.drupal.org/project/drupal/issues/3343911
I'd like to summarise the above (after gathering information from the multiple sources):
Drupal Extension v5 is currently compatible with D9 and is tested to be compatible (in CI).
However, due to the issue described here it is not installable if the consumer site uses drupal/core-dev
metapackage
Currently, CI for Drupal Extension does not use drupal/core-dev
, which "masks" this problem.
@Berdir and @catch have discussed this on Slack and per @berdir's comment in Slack:
Note that the mentioned incompatibility is with behat Drupal extension 5.x alpha. Committing this would in turn then cause the opposite conflict with the stable 4.x releases.
It is now not clear what the intention of Drupal Extension to support D9 - supporting only sites that do not use drupal/core-dev
is not a feasible option (https://github.com/drupal-composer/drupal-project prescribes it as a best practice).
@Berdir
Can we mark friends-of-behat/mink-browserkit-driver
(or whatever the conflict is) as a conflict for 9.5.x
branch and action the change for 9.6.x
branch (so that at least next minor D9 would support v5). The patch in https://www.drupal.org/project/drupal/issues/3343911 has passed CI, so technically it looks like it is stable.
I'm wondering if more considerations could be given by the core team.
There is no next minor Drupal 9 version, Drupal 9 is EOL in December. Either stick to using 3.x on Drupal 9 or don't use drupal/core-dev. And the medium/long-term fix that you have to do anyway this year is upgrading to Drupal 10.
Problem
Could not update to 5.0.0 alpha because of conflicts with drupal/core-dev. I required the 5.0.0 alpha because I need to remove the goutte-drive requirement to use Guzzle 7 fixed on commit https://github.com/jhedstrom/drupalextension/commit/2ab66a7eae53ae4e1e5824edaa72e98039b084db
Possible Solution
I am not sure if this is the problem, drupalextension and core-dev require the same projects different repositories: https://github.com/jhedstrom/drupalextension/blob/v5.0.0alpha1/composer.json#L27
https://github.com/drupal/core-dev/blob/9.5.3/composer.json#L15
Error: