Skip to content
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

Errors with PHP 8.1 and SDK 6.18 #345

Open
riwalker opened this issue Aug 16, 2024 · 0 comments
Open

Errors with PHP 8.1 and SDK 6.18 #345

riwalker opened this issue Aug 16, 2024 · 0 comments

Comments

@riwalker
Copy link

Using PHP 8.1, Opencart 3.0.3.9, and Braintree Payments 'BraintreePaymentGatewayPro-2024-3-12'
We were getting errors, which we know were related to lack of PHP 8.1 support from the SDK.
We only use the 'lib' folder from the SDK

“To install it, you unzip the bundle you download and find the "lib" directory inside. You use that to overwrite the /system/library/braintree/lib/ directory on your server. (I would advise making a backup of the existing "lib" directory first, just in case anything happens that will allow you to restore it easily.) ”

I performed an upgrade from the latest PHP library ‘braintree-php-6.19.0’
Seems to have gone ok, I complete a test purchase, and went through ok, and no PHP errors

with prior 6.18, we had the following errors:
2024-08-14 20:54:11 - PHP Unknown: Return type of Braintree\Error\ErrorCollection::count() should either be compatible with Countable::count(): int, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home/myweb/storage/vendor/braintree/braintree_php/lib/Braintree/Error/ErrorCollection.php on line 35 2024-08-14 20:54:11 - PHP Unknown: Return type of Braintree\Collection::count() should either be compatible with Countable::count(): int, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home/myweb/storage/vendor/braintree/braintree_php/lib/Braintree/Collection.php on line 97 2024-08-14 20:54:11 - PHP Unknown: Return type of Braintree\Collection::getIterator() should either be compatible with IteratorAggregate::getIterator(): Traversable, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home/myweb/storage/vendor/braintree/braintree_php/lib/Braintree/Collection.php on line 108 2024-08-14 20:54:11 - PHP Unknown: Return type of Braintree\Collection::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 /home/myweb/storage/vendor/braintree/braintree_php/lib/Braintree/Collection.php on line 155 2024-08-14 20:54:11 - PHP Unknown: Return type of Braintree\Collection::offsetGet($offset) should either be compatible with ArrayAccess::offsetGet(mixed $offset): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home/myweb/storage/vendor/braintree/braintree_php/lib/Braintree/Collection.php on line 143 2024-08-14 20:54:11 - PHP Unknown: Return type of Braintree\Collection::offsetSet($offset, $value) should either be compatible with ArrayAccess::offsetSet(mixed $offset, mixed $value): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home/myweb/storage/vendor/braintree/braintree_php/lib/Braintree/Collection.php on line 120 2024-08-14 20:54:11 - PHP Unknown: Return type of Braintree\Collection::offsetUnset($offset) should either be compatible with ArrayAccess::offsetUnset(mixed $offset): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home/myweb/storage/vendor/braintree/braintree_php/lib/Braintree/Collection.php on line 131 2024-08-14 20:55:27 - PHP Unknown: Return type of Braintree\Error\ErrorCollection::count() should either be compatible with Countable::count(): int, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home/myweb/storage/vendor/braintree/braintree_php/lib/Braintree/Error/ErrorCollection.php on line 35 2024-08-14 20:55:27 - PHP Unknown: Return type of Braintree\Collection::count() should either be compatible with Countable::count(): int, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home/myweb/storage/vendor/braintree/braintree_php/lib/Braintree/Collection.php on line 97 2024-08-14 20:55:27 - PHP Unknown: Return type of Braintree\Collection::getIterator() should either be compatible with IteratorAggregate::getIterator(): Traversable, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home/myweb/storage/vendor/braintree/braintree_php/lib/Braintree/Collection.php on line 108 2024-08-14 20:55:27 - PHP Unknown: Return type of Braintree\Collection::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 /home/myweb/storage/vendor/braintree/braintree_php/lib/Braintree/Collection.php on line 155 2024-08-14 20:55:27 - PHP Unknown: Return type of Braintree\Collection::offsetGet($offset) should either be compatible with ArrayAccess::offsetGet(mixed $offset): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home/myweb/storage/vendor/braintree/braintree_php/lib/Braintree/Collection.php on line 143 2024-08-14 20:55:27 - PHP Unknown: Return type of Braintree\Collection::offsetSet($offset, $value) should either be compatible with ArrayAccess::offsetSet(mixed $offset, mixed $value): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home/myweb/storage/vendor/braintree/braintree_php/lib/Braintree/Collection.php on line 120 2024-08-14 20:55:27 - PHP Unknown: Return type of Braintree\Collection::offsetUnset($offset) should either be compatible with ArrayAccess::offsetUnset(mixed $offset): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home/myweb/storage/vendor/braintree/braintree_php/lib/Braintree/Collection.php on line 131 2024-08-14 20:55:39 - PHP Unknown: Return type of Braintree\Error\ErrorCollection::count() should either be compatible with Countable::count(): int, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home/myweb/storage/vendor/braintree/braintree_php/lib/Braintree/Error/ErrorCollection.php on line 35 2024-08-14 20:55:39 - PHP Unknown: Return type of Braintree\Collection::count() should either be compatible with Countable::count(): int, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home/myweb/storage/vendor/braintree/braintree_php/lib/Braintree/Collection.php on line 97 2024-08-14 20:55:39 - PHP Unknown: Return type of Braintree\Collection::getIterator() should either be compatible with IteratorAggregate::getIterator(): Traversable, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home/myweb/storage/vendor/braintree/braintree_php/lib/Braintree/Collection.php on line 108 2024-08-14 20:55:39 - PHP Unknown: Return type of Braintree\Collection::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 /home/myweb/storage/vendor/braintree/braintree_php/lib/Braintree/Collection.php on line 155 2024-08-14 20:55:39 - PHP Unknown: Return type of Braintree\Collection::offsetGet($offset) should either be compatible with ArrayAccess::offsetGet(mixed $offset): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home/myweb/storage/vendor/braintree/braintree_php/lib/Braintree/Collection.php on line 143 2024-08-14 20:55:39 - PHP Unknown: Return type of Braintree\Collection::offsetSet($offset, $value) should either be compatible with ArrayAccess::offsetSet(mixed $offset, mixed $value): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home/myweb/storage/vendor/braintree/braintree_php/lib/Braintree/Collection.php on line 120 2024-08-14 20:55:39 - PHP Unknown: Return type of Braintree\Collection::offsetUnset($offset) should either be compatible with ArrayAccess::offsetUnset(mixed $offset): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home/myweb/storage/vendor/braintree/braintree_php/lib/Braintree/Collection.php on line 131

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant