-
Notifications
You must be signed in to change notification settings - Fork 56
Closed
Labels
bugan unexpected problem or unintended behavioran unexpected problem or unintended behavior
Description
Weird bug here. If I send an email with a subject line containing an accented character, it works fine as long as the subject is 55 characters long or less:
message <- gm_mime() |>
gm_to("testreceive@gmail.com") |>
gm_from("testsend@gmail.com>") |>
gm_subject("áaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa") |>
gm_html_body("hello world")
gm_send_message(message)
When viewed in gmail, the subject line reads as intended.
But if the subject line is 56 characters long (or longer), it comes out garbled:
message <- gm_mime() |>
gm_to("mikeblazanin@gmail.com") |>
gm_from("Zotero Recommender <ZoteroRecommender@gmail.com>") |>
gm_subject("áaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa") |>
gm_html_body("hello world")
gm_send_message(message)
When viewed in gmail, the subject line reads as: "=?utf-8?B?w6FhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFh"
Other notes: subject lines without accents more than 55 characters do just fine. The error still appears if you create a draft then send the draft.
Session info: I'm using a cached login to set up my authorization before running the example code above
options(gargle_oauth_cache = ".gargle_cache",
gargle_oauth_email = TRUE)
gm_auth_configure(path = "./data-raw/client_secret_abcde.json")
gm_auth(email = "testsend@gmail.com",
token = "./data-raw/gmailr-token.rds")
kendavidn
Metadata
Metadata
Assignees
Labels
bugan unexpected problem or unintended behavioran unexpected problem or unintended behavior