When sending via the Gmail API, is it possible to include special characters within the sender name?
For example, when trying to send with the following code, the sender name is omitted and it only displays the email address.
When including an ascii based sender name, it works without issue.
import base64
from email.mime.text import MIMEText
fromName = u'«ταБЬℓσ»' #contains special characters
fromEmail = 'name@domain.com'
message = MIMEText(bodyHtml, 'html', 'utf-8')
message['From'] = u'{} <{}>'.format(fromName, fromEmail).encode('utf-8')
message['to'] = unicode(toEmail)
message['reply-to'] = unicode(replyTo)
message['subject'] = unicode(subject)
message_obj = {'raw': base64.urlsafe_b64encode(message.as_string())}