Skip to content

Upgrade PHP requirement: 8.0 → 8.1, code adjustments #442

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

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

enmaboya
Copy link
Contributor

@enmaboya enmaboya commented Jun 30, 2025

Reasons for changing the minimum version:

  1. The minimum supported PHP version is 8.1. ;
  2. Upgrading from 8.0 to 8.1 is very straightforward, as there are no backward compatibility issues;
  3. PHP 8.1 introduces enums, which can effectively replace the enums from Funeralzone\ValueObjects;

@enmaboya enmaboya force-pushed the chore/bump-php-min-8.1 branch 4 times, most recently from 9288d5a to 82e2977 Compare June 30, 2025 13:23
@enmaboya enmaboya force-pushed the chore/bump-php-min-8.1 branch from 82e2977 to 2aab761 Compare June 30, 2025 13:30
@enmaboya enmaboya force-pushed the chore/bump-php-min-8.1 branch 3 times, most recently from 7e91eec to 3d62c02 Compare June 30, 2025 14:25
@enmaboya enmaboya marked this pull request as ready for review July 1, 2025 11:37
@enmaboya enmaboya force-pushed the chore/bump-php-min-8.1 branch from 3d62c02 to 1f0a5b6 Compare July 1, 2025 11:42
parameters:
ignoreErrors:
-
message: '#^Deprecated in PHP 8\.4\: Parameter \#1 \$session \(Gnikyt\\BasicShopifyAPI\\Session\) is implicitly nullable via default value null\.$#'
Copy link
Owner

@Kyon147 Kyon147 Jul 16, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am thinking, these errors will need to be fixed eventually, as 8.1 / 8.2 won't be support for a lot longer so we will need to move over the 8.3 but might be worth just jumping to 8.4 when that refactor happens.

This would mean bringing in our own API package I think. Unless we can use something Shopify already has but I've not looked.

Thoughts @enmaboya

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Kyon147 Fork of the package is currently on hold due to work commitments. However, I expect to publish it soon with fixes for the issues flagged by PHPStan and a minimum PHP version of 8.1 (with further updates planned in the future).

@Kyon147 Kyon147 added PR: Approved Release: Major Requires a major release as it has breaking changes labels Jul 16, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
PR: Approved Release: Major Requires a major release as it has breaking changes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants