1

enter image description hereWhen I try to send two or more variants of messages, sending is paused and I get an error in log: subject is empty, although I have set it. But if I send simple message with one variants, message will send successfully without any errors and the subject is correct. I have "Set Page Title" rendering in presentation details.

Sitecore 8.2 update 7, Exm 3.5

ERROR Message sending error: System.AggregateException: One or more errors occurred. ---> System.ArgumentException: Empty strings are not allowed.
Parameter name: message.Subject
   at Sitecore.Diagnostics.Assert.ArgumentNotNullOrEmpty(String argument, String argumentName)
   at Sitecore.EDS.Core.Net.Smtp.MessageTransport`1..ctor(EmailMessage message)
   at Sitecore.EDS.Providers.CustomSmtp.DispatchProvider.<SendEmailAsync>d__3.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at Sitecore.EDS.Core.Dispatch.DispatchProviderBase.<SendAsync>d__5.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at Sitecore.EDS.Core.Dispatch.DispatchManager.<SendAsync>d__6.MoveNext()
   --- End of inner exception stack trace ---
   at System.Threading.Tasks.Task`1.GetResultCore(Boolean waitCompletionNotification)
   at Sitecore.EmailCampaign.Cm.Pipelines.SendEmail.SendEmail.Process(SendMessageArgs args)
   at (Object , Object )
   at Sitecore.Pipelines.CorePipeline.Run(PipelineArgs args)
   at Sitecore.Pipelines.DefaultCorePipelineManager.Run(String pipelineName, PipelineArgs args, String pipelineDomain, Boolean failIfNotExists)
   at Sitecore.Pipelines.DefaultCorePipelineManager.Run(String pipelineName, PipelineArgs args, String pipelineDomain)
   at Sitecore.Modules.EmailCampaign.Core.PipelineHelper.RunPipeline(String pipelineName, PipelineArgs args)
   at Sitecore.Modules.EmailCampaign.Core.Dispatch.DispatchTask.OnSendToNextRecipient()
---> (Inner Exception #0) System.ArgumentException: Empty strings are not allowed.
Parameter name: message.Subject
   at Sitecore.Diagnostics.Assert.ArgumentNotNullOrEmpty(String argument, String 
   argumentName)
   at Sitecore.EDS.Core.Net.Smtp.MessageTransport`1..ctor(EmailMessage message)
   at Sitecore.EDS.Providers.CustomSmtp.DispatchProvider.<SendEmailAsync>d__3.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at Sitecore.EDS.Core.Dispatch.DispatchProviderBase.<SendAsync>d__5.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at Sitecore.EDS.Core.Dispatch.DispatchManager.<SendAsync>d__6.MoveNext()<---
  • Does this happen when you use the default templates, or only with a custom template? – Jacob Nielsen Nov 14 '18 at 9:23
  • I have this problem for both templates. Also I have noticed that message item with two variants has body field with link on himself and item with on variant has link on messageRoot item. As I understand by sitecore code in WebPageMailSource class, by this body field we should get target item and then read his subject field. – Андрей Величко Nov 14 '18 at 9:39
  • There are no (known) bugs around this feature with the default templates, so could you please try and recheck e.g. using the "One-column message" template? Have you done any customization of the pipelines or other EXM functionality? Do you see any errors in the EXM or Sitecore log files? What value have you specified for the subject of the email campaign? – Jacob Nielsen Nov 14 '18 at 15:09
  • I have the same for One-column template. I have created a message with subject "a" and "b". I have some custom pipelines. But the exception throws before they are called. I have created pipeline for investigate with this code MessageItem messageItem = this._factory.GetMessageItem(args.MessageId); I copied it from this pipeline HandleMessageEventBase.GetMessage For one variant message it returns real subject and for two variants the subject field is "$title$". Because in sitecore WebPageMail class we have this logic: return base.Subject ?? (this.Subject = "$title$"); – Андрей Величко Nov 15 '18 at 15:53
0

Make sure that The Set Page Title rendering is added at the Shared Layout.

If it is added to the Final Layout, it will not work.

| improve this answer | |
0

I had ContentTesting.AutomaticContentTesting.Enabled set to false at Sitecore.ContentTesting.config. After I have changed it to true ab testing works correctly.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.