This is a strange one. I've had a working MailChimp, Gibbon, RoR app going for a couple of years now, and I went to go use part of my app this week and realized that the integration was no longer working. I am not receiving any errors, and some basic testing shows that the exception section of the code is never called.
Here is the code I am using:
begin
gb = Gibbon::API.new(mailchimp_api_key)
gb.lists.subscribe( id: mailchimp_list_id, email: {email: email} )
rescue Gibbon::MailChimpError => e
logger.error "Mailchimp threw an error. The code is: #{e.code}, with message: #{e.message}"
end
Some code edited for readability, but assume that the variables are defined and no errors are thrown.
What I'm looking for is some debugging help. I can't seem to find a way to debug the integration to know if there is something silently failing or not. Does anyone have any tips for debugging this outside of trying to catch a raised exception?