New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix to Email Sending Issue with SparkPost #9006
Conversation
Codecov Report
@@ Coverage Diff @@
## 3.0 #9006 +/- ##
=========================================
Coverage 35.24% 35.24%
- Complexity 27900 27907 +7
=========================================
Files 1731 1731
Lines 96443 96452 +9
=========================================
+ Hits 33987 33995 +8
- Misses 62456 62457 +1
|
@dennisameling may you please review this issue, it is blocking a lot of people who use sparkpost |
@mabumusa1 Thanks, will test on Wednesday :) |
@mabumusa1 Can you add title of this pull requests and description? |
@kuzmany changed the title and added description |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Created a Sparkpost account to test this PR. If the 2nd reviewer needs my account to test, please reach out via Mautic Slack.
Can confirm the bug exists:
[2020-07-15 19:18:58] mautic.ERROR: [MAIL ERROR] content.headers json dictionary value has type 'number' when expecting type 'string' (send); <REDACTED> {"exception":"[object] (Swift_TransportException(code: 0): content.headers json dictionary value has type 'number' when expecting type 'string' at /var/www/html/app/bundles/EmailBundle/Swiftmailer/Transport/AbstractTokenArrayTransport.php:300)"} []
After applying this PR, it works as expected. Thanks @mabumusa1! 🚀
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Confirm the bug before applying the PR:
[2020-07-19 20:51:46] mautic.ERROR: [MAIL ERROR] content.headers json dictionary value has type 'number' when expecting type 'string' (send); HenryLCatalano@einrot.com, ruth@cheesley.me.uk {"exception":"[object] (Swift_TransportException(code: 0): content.headers json dictionary value has type 'number' when expecting type 'string' at /Users/ruth.cheesley/Sites/local.mautic3/mautic/app/bundles/EmailBundle/Swiftmailer/Transport/AbstractTokenArrayTransport.php:300)"} []
Emails successfully sent when the PR is applied! 🎉
Description:
This issue happen when you use Sparkpost, Swift Mail throws an exception and the emails are not sent.
Steps to re-produce:
mautic.ERROR: [MAIL ERROR] content.headers json dictionary value has type 'number' when expecting type 'string' Log data: !! content.headers json dictionary value has type 'number' when expecting type 'string' (code: 0) (send); victorcampuzano@XXXXXXXXXXXXXXX.com {"exception":"[object] (Swift_TransportException(code: 0): content.headers json dictionary value has type 'number' when expecting type 'string'\nLog data:\n!! content.headers json dictionary value has type 'number' when expecting type 'string' (code: 0) at