parcelvoy/platform

Journey does not send last email

Closed this issue · 5 comments

I have a journey that

  • has an entrance based on the user_created event
  • sends a first email
  • delays for a minute
  • sends a 2nd email
  • sends a 3rd email (without delay)

Emails no. 1 and 2 are sent fine. Email no. 3 is not sent. I expected it to be sent right after email no. 2.

Detail: Email no. 3 is called "Added later" because I ran a previous test where it wasn't there at first. I wanted to know what happens when I add another email later while the users are already on the journey. Nothing happened.

But even when I subscribe a totally new user to the same journey, email no. 3 is not sent to them! Why?

Here is a screenshot of the journey details:

CleanShot 2024-04-05 at 11 57 38@2x

@mattes3 I was having a hard time reproducing this one on my end / getting to the bottom of it and am still unsure if I've identified the problem you are having.

The first situation you described is normal, once a user completes a journey, adding a new step to that journey wont re-enter them into it. That would cause all sorts of nightmares if you ever wanted to modify a journey.

The second situation is not normal. Based on the code itself, there is nothing that would prohibit back to back sending, it should just work. After trying like 50 different times to reproduce I finally had it happen a couple of times, in every case it was the email sender blocking the send with an error like the following: 421-4.3.0 Temporary System Problem.. This led me down the path of error handling and we aren't appropriately closing the journey loop when a campaign fails to send. This will be addressed in the next version (#434).

Unsure if that is the problem you are experiencing, but was unable to replicate under any circumstances except a sending failure. If you could check under the user in question to see if there is a 'email_failed` event that would be super helpful. If it's still happening, if you have any additional details that could help in debugging please send them over!

Thanks, @pushchris, for taking care of this. Yes, indeed, it is possible that Amazon SES threw an error because the two emails were right after one another. I now configured the AWS SES integration to send a max. of 12 emails per second, as SES allows me to send 14 per second (let's be on the safe side here).

I will now update to the latest version and try a journey with a bunch of 50 users, to see if this works.

OMG, I finally discovered the true reason why this happened: My last email had no "from" address so it failed to send. Sorry to have bothered you with this, Chris!

It's all good, we found an edge case along the way so time well spent. The fact that you weren't able to identify that as the cause early enough is probably also problematic, we'll need to find some ways to highlight that the campaign wasn't valid. When doing a normal blast campaign this check happens when you try to send it, for journeys because there is no "launching" or a campaign we don't currently run that step.

I've added some improvements to the UI surrounding campaign templates to hopefully make it more clear when these issues come up. There is a validation step inside of an email send that will preemptively fail it if it doesn't pass parameter validation and log the exact parameter at fault into the email_failed event. The template design screen also has warning tags on any fields that are missing a parameter