Active
Project:
Commerce Funds
Version:
8.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
11 May 2020 at 01:43 UTC
Updated:
21 Oct 2024 at 15:41 UTC
Jump to comment: Most recent
it is only compatible with ^8.7.7 || ^9 which is in the composer file.
Comments
Comment #2
socialnicheguru commenteddrush en commerce_funds
The following extensions will be enabled: commerce_funds
Do you really want to continue? (y/n): y
Symfony\Component\Validator\Exception\UnexpectedTypeException: Expected argument of type "array or Traversable and [error]
ArrayAccess", "string" given in
drupal-8.8/vendor/symfony/validator/Constraints/CollectionValidator.php:37
Comment #3
aporieHi,
I don't see why your issue should be related to commerce_funds, it seems more than a composer dependency issue. I'd run
composer update --with-dependenciesto try to resolve it.Regarding the drupal core version, according to this post core_requirement is not available before 8.7.7 and that's what is in the .info file.
I close the ticket because I wasn't able to reproduce. Feel free to comment, reopen or create a new ticket if needed.
Comment #4
socialnicheguru commentedIn the error that I got
Symfony\Component\Validator\Exception\UnexpectedTypeException: Expected argument of type "array or Traversable and ArrayAccess", "string" given in
drupal-8.8/vendor/symfony/validator/Constraints/CollectionValidator.php:39
In debugging the string that caused the error was "^(\w|-)+$" which comes from the comemrce_funds module
grep -in -F "^(\w|-)+$" -d recurse *
contrib/commerce_funds/commerce_funds.routing.yml:53: request_hash: ^(\w|-)+$
contrib/commerce_funds/commerce_funds.routing.yml:62: request_hash: ^(\w|-)+$
contrib/commerce_funds/commerce_funds.routing.yml:98: method: ^(\w|-)+$
contrib/commerce_funds/commerce_funds.routing.yml:135: transaction_hash: ^(\w|-)+$
contrib/commerce_funds/commerce_funds.routing.yml:145: transaction_hash: ^(\w|-)+$
Comment #5
aporieDid you
composer update --with-dependencies?What's triggering the error are simple regex validators, I don't know why your Constraints/CollectionValidator is waiting for an array here.
I've tried on a fresh install this morning and didn't get any issue.
Comment #6
aporieComment #7
wqmeng commentedHello,
I also find this problem on the Drupal 10.1.4-dev. Here is the error.
What I have modification is to change the method parameter to be the following in the file
web/modules/contrib/commerce_funds/commerce_funds.routing.ymlBut it will lose the regex validator, do not know how keep the validation if possible?
Thank you.
Comment #8
wqmeng commentedChange the status to be active.
Comment #9
aporieI'm getting some work done for a new release.
Reading this issue again, I'm pretty sure it's related to a payment method you are using.
Can I ask which ones you were using?
I'm revamping this route anyway as I mistakenly named a plugin "bank-account" while it should have been "bank_account".