- Issue created by @yanniboi
I am also having problems after upgrading to 3.0.0-rc4. My code calls MailchimpLists->getSegments(), which gives rise to the error:
Call to a member function request() on string in Mailchimp\MailchimpLists->getSegments() (line 595 of /home/xxx/yyy/zzz/vendor/thinkshout/mailchimp-api-php/src/MailchimpLists.php)
MilchimpLists extends MailchimpApiUser, and line 595 is:
return $this->api_class->request('GET', '/lists/{list_id}/segments', $tokens, $parameters);
So, it looks like a problem with
$this->api_class
.
This might not be the same as the originally reported problem, but I suspect it is related.
Downgrading back to v2.1.3 fixes the problem.- @yanniboi opened merge request.
- Status changed to Needs review
over 1 year ago 7:55am 25 April 2023 - π¬π§United Kingdom yanniboi UK
I am not sure if @dabley's issue is related, however it looks like since mailchimp-api-php has release release candidate 6 with the API fix included we can now update the version dependency of mailchimp module.
- π¨π¦Canada sagesolutions
I am also get this issue when I upgraded to version 2.2.0
Error: Call to a member function request() on string in Mailchimp\MailchimpLists->getMemberInfo() (line 354 of /var/www/xxx/yyy/vendor/thinkshout/mailchimp-api-php/src/MailchimpLists.php)
- πΊπΈUnited States bdimaggio Boston, MA
Just wanted to let folks know we're on this and will address within the week.
- Status changed to Fixed
over 1 year ago 11:23pm 26 May 2023 - πΊπΈUnited States aprice42
Just rolled a new release that includes a fix for this.
Automatically closed - issue fixed for 2 weeks with no activity.
- Status changed to Fixed
about 1 year ago 3:08am 14 October 2023 - π¨π¦Canada sagesolutions
I tried on the 2.2.2 version and I am still getting the following error
`Error: Call to a member function request() on string in Mailchimp\MailchimpLists->getMemberInfo()`
Here is my code snippet below that subscribes a user to a list once they complete the checkout process.
/** @var \Drupal\commerce_order\Entity\OrderInterface $order */ $order = $event->getEntity(); $config = Drupal::config('mailchimp.settings'); $api_key = $config->get("api_key"); $mailChimpLists = new MailchimpLists($api_key); $listID = '123456789'; $email = $order->getEmail(); try { $member = $mailChimpLists->getMemberInfo($listID, $email); } catch (Exception $exception) {