You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Description
We have encountered compatibility issues with the Wallee SDK used in our OpenCart shop when running on PHP 8.1 The issue arises due to the lack of proper type declarations in methods that implement the ArrayAccess interface in the Wallee SDK. Specifically, this affects the Transaction and Address classes.
Error Messages
The following error messages are observed in the system logs:
PHP Unknown: Return type of Wallee\Sdk\Model\Transaction::offsetExists($offset) should either be compatible with ArrayAccess::offsetExists(mixed $offset): bool, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /path/to/wallee-sdk/lib/Model/Transaction.php on line 2295
Similar error messages for methods offsetGet, offsetSet, and offsetUnset in both Transaction and Address classes.
Expected Behavior
The methods in the Wallee SDK that implement the ArrayAccess interface should have compatible type declarations as per the PHP 8.1 requirements.
Steps to Reproduce
Upgrade the PHP version to 8.1
Run the OpenCart shop with the Wallee SDK integrated.
Observe the error logs.
Possible Solutions
Update the Wallee SDK to ensure compatibility with PHP 8.1, including proper type declarations for methods implementing interfaces like ArrayAccess.
As a temporary fix, use the #[\ReturnTypeWillChange] attribute to suppress the type declaration compatibility warnings.
Additional Information
OpenCart Version: 3.0.3.8
Wallee SDK Version: 1.0.56
PHP Version: 8.1
We would appreciate guidance on how to resolve this issue or information about any forthcoming updates that address this compatibility concern.
The text was updated successfully, but these errors were encountered:
Description
We have encountered compatibility issues with the Wallee SDK used in our OpenCart shop when running on PHP 8.1 The issue arises due to the lack of proper type declarations in methods that implement the ArrayAccess interface in the Wallee SDK. Specifically, this affects the Transaction and Address classes.
Error Messages
The following error messages are observed in the system logs:
PHP Unknown: Return type of Wallee\Sdk\Model\Transaction::offsetExists($offset) should either be compatible with ArrayAccess::offsetExists(mixed $offset): bool, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /path/to/wallee-sdk/lib/Model/Transaction.php on line 2295
Similar error messages for methods offsetGet, offsetSet, and offsetUnset in both Transaction and Address classes.
Expected Behavior
The methods in the Wallee SDK that implement the ArrayAccess interface should have compatible type declarations as per the PHP 8.1 requirements.
Steps to Reproduce
Upgrade the PHP version to 8.1
Run the OpenCart shop with the Wallee SDK integrated.
Observe the error logs.
Possible Solutions
Update the Wallee SDK to ensure compatibility with PHP 8.1, including proper type declarations for methods implementing interfaces like ArrayAccess.
As a temporary fix, use the #[\ReturnTypeWillChange] attribute to suppress the type declaration compatibility warnings.
Additional Information
OpenCart Version: 3.0.3.8
Wallee SDK Version: 1.0.56
PHP Version: 8.1
We would appreciate guidance on how to resolve this issue or information about any forthcoming updates that address this compatibility concern.
The text was updated successfully, but these errors were encountered: