If the API key changed the Campaign is broken with below errors

InvalidArgumentException: The URI '' is invalid. You must use a valid URI scheme. in Drupal\Core\Url::fromUri() (line 280 of /..../core/lib/Drupal/Core/Url.php).
An error occurred while getting campaigns: 404: Resource Not Found - The requested resource could not be found.

Notice: Trying to get property of non-object in Drupal\mailchimp_campaign\Controller\MailchimpCampaignController->overview() (line 38 of /...../modules/mailchimp/modules/mailchimp_campaign/src/Controller/MailchimpCampaignController.php).

and after deleting the mailchimp_campaign it works fine !

CommentFileSizeAuthor
#3 2776259-3.patch1.25 KBsamuel.mortenson

Comments

AhmadZain created an issue. See original summary.

thejimbirch’s picture

I was getting this error also. I was able to get rid of it by first going to the Uninstall Module page, and checking the Mailchimp Campaign module. The next screen says that you need to "Delete all Mailchimp campaign entities" first. I clicked that link, and removed the entities. Now the Campaign screen loads.

samuel.mortenson’s picture

Status: Active » Needs review
StatusFileSize
new1.25 KB

This patch should help to raise the error in a more friendly way to users.

rjacobsen0’s picture

Status: Needs review » Reviewed & tested by the community

I was not able to reproduce the problem, but I still like the patch as a nicer error message. Committing.

rjacobsen0’s picture

Status: Reviewed & tested by the community » Fixed

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.