in mail.template when you use a reference to a text object containing a carriage return '\n', the mail is sent with a bounce address because the address field is empty, if you use ${object.XXXXXX.replace('\n',', ')} your problem is solved, it will be good to update python code to replace subject carriage return by a sign to avoid sending a bounce message on server.
In my example the object is a textbox with sometimes multiline.
In my example the object is a textbox with sometimes multiline.
For me that's the reason were some message was sent correctly when the object is without carriage return and other are sent with bounce address.