-
Notifications
You must be signed in to change notification settings - Fork 26
Mismatch between requirements #42
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
Comments
Oh my that sucks big time ;( Could you try to remove |
@BorisovskiP were you able to get it running the way I described it? |
@shochdoerfer as we have other modules that are still not compatible with 2.4.0, we are waiting on them to update their dependencies so we can proceed with the update. I will notify you when we have done this. |
Removing and re-installing this module does not work as the requirements are still incompatible as stated in the initial description. We just updated the version constraint for |
So the big question still is how this issue should be handled by default. I tend to vote for "use the PHPStan version Magento uses". I strongly believe a Magento package should be installable on a clean Magento installation without any issues. Hence, the PHPStan versions must not conflict. What do you think, @shochdoerfer? |
Yeah, it kind of sucks to downgrade phpstan again but I am fully with you @sprankhub. It needs to be easy to install the module in any Magento environment and it would suck big time if the phpstan rules shipped with Magento would not work anymore after the phpstan upgrade. So there's only one choice here, sadly. I don't think we can support multiple phpstan versions, especially not "latest" as usually there's lots of change happening. I'd rather only support the phpstan version that is shipped with the latest, stable Magento version. |
@sprankhub feel free to prep a PR for this, I am way too busy these days to get this going ;( |
Fixed in master, will prepare a new release soonish. |
@BorisovskiP: can you answer these questions please?
|
Following @hostep's remarks in #43 I think we have re-evaluate the approach taken and adapt. The original goal was to allow people to easily upgrade their Magento 2.3 instance with the I would not want to restrict people using Ideally, we could keep up with phpstan development and adapt more often than Magento does (or can). Or at least be a bit more independent from Magento's release cycles. So my plan would be to release a bugfix release that would revert #43 and add a bit of documentation to describe the upgrade process when coming from Magento 2.3. What do you people think? @hostep @BorisovskiP @sprankhub @torhoehn - I would really get this right this time :) |
Are there valid cases of making If yes, then we should indeed make it possible to install it in Magento 2.4, and then I would suggest the constraint to be changed to at least allow it to be installed with When you install I also don't really understand why in Magento 2 they limit phpstan to 0.12.23 as the highest version, this was added in scope of adding support for Mysql 8, but makes little sense to me: magento/magento2@700de11 |
Yes, there are definitely valid use cases for making I think changing the requirement to something like I also think a ticket should be created in the M2 repo to get rid of the upper PHPStan version constraint. Would anyone of you guys be willing to do so? |
Ok, that makes sense @sprankhub ! I've opened a pull request on the M2 repo to allow >= 0.12.3 < 0.13.0 versions of phpstan to be installed: magento/magento2#30581 Unfortunately for this repo, we will need to change the requirements to the closest possible to the actual minimum required version, which seems to be 0.12.26, while still allowing it to be installed on Magento 2.4.x, so I would suggest: |
Sounds reasonable to me, yes. Let us see what @shochdoerfer says :) Thanks @hostep! |
Sorry, got hit hard by a migraine yesterday, not sure if this happened because of this issue or not :P A bit busy today, will try to reply to you later... |
Was hoping to get this sorted before my MageCONF 2020 presentation today but life got in my way. Sadly we can't aim at So I would aim at Or do we have another option that I currently not see? |
AFAIK, the new |
Right, I forgot about the Then I think it boils down to 2 options:
For now, I am fine with option 1. Depending on Magento's reasons for the hard version limit, future versions might not be compatible with Magento core. PHPStan is moving fast and I would at least try to keep up to have all the goodness available :) |
I've just tried upgrading from version 0.3.0 to 0.4.0 of So I'm more in favor of option 2, but maybe we can get a compromise by still using We'd then just have to put 2 different statements in the installation section of the readme file, one using So I agree with @sprankhub here. The other option is actually going for suggestion number 2, because the constraint on I really dislike option 1, because it would mean we can't use the latest and greatest of |
Ok, so that's 1,75 votes for option 2, what about you @sprankhub? |
TBH, I think you ignore my proposal ;-)
I do not see any disadvantage of this. Only advantages:
Tell me if I miss anything. |
@sprankhub then let's go with the "nicest approach" that I may or may not have ignored :) Any takers for the PR? Are you all cool with releasing this as a patch release? |
PR created: #44 I'm fine with a patch release! |
Patch relase 0.4.1 published. Thanks a lot! |
It is not possible to update to magento 2.4.0 community edition because your module requires phpstan/phpstan: ^0.12.24, while magento requires phpstan/phpstan: >=0.12.3 <=0.12.23 (https://packagist.org/packages/magento/community-edition).
The text was updated successfully, but these errors were encountered: