FosterCommerce / klaviyoconnect

A plugin for Craft CMS. Grow your ecommerce business with smarter email automations.
https://klaviyoconnect.fostercommerce.com/
Other
10 stars 10 forks source link

"This update requires PHP ^7.2, but your environment is currently running PHP 8.0.8" #88

Closed iamkeir closed 2 years ago

iamkeir commented 2 years ago

We are being prompted to run an update but receiving "This update requires PHP ^7.2, but your environment is currently running PHP 8.0.8". This is curious as the previous version of the app has been running on v8 - so I'm guessing there is a misguided gremlin in the system :D

Great plugin, btw - thanks!

peteeveleigh commented 2 years ago

Hi @iamkeir Yeah we had a few issues last week regarding getting both a Craft 3 and a Craft 4 version available simultaneously. We have had to add some version constraints to ensure the correct version is installed on each system.

I think I know what's up here. Could you please confirm the Craft version, plugin version you currently have installed, and which plugin version it's trying to update to?

You could try installing the current version on the dev-develop-craft3 branch? This has a constraint which should allow installation on Craft 3 with PHP 8.

You can do this by changing your composer.json requirement to

"fostercommerce/klaviyoconnect": "dev-develop-craft3"

and running composer update

iamkeir commented 2 years ago

@fantasticmachine thanks for fast reply! Yes, we're Craft 3 on PHP 8, specifically: PHP 8.0.8 Craft Pro 3.7.46 Klaviyo Connect 4.0.10

And I've got two updates listed for Klaviyo Connect, 4.0.11 and 4.0.12.

I've tried your suggestion which seems to have done the trick for now. Do we need to be mindful of new versions using this method?

peteeveleigh commented 2 years ago

@iamkeir That's good. You won't have to worry about new versions going forward. I cut the 4.0.12 release just before I saw your issue this morning and didn't want to do another so soon and I wanted to be careful given the tangle it got into last week!

I'll get 4.0.13 out later today or tomorrow with support for Craft 3 on PHP 8. You can change then your composer requirement back to "^4.0".

For the record, going forward, all releases for Craft 3 will be on that dev-develop-craft3 branch but I will tag releases on there. Craft 3 versions of the plugin will all be 4.0.x with Craft 4 releases being on 5.0.x

peteeveleigh commented 2 years ago

@iamkeir I had a minute before I needed to dash out, so I have published a release for 4.0.13. You can now change your composer file requirement back to "^4.0" and it should be fine.

iamkeir commented 2 years ago

@fantasticmachine YOU DE BEST! Thank you for sorting so quickly.