-
Notifications
You must be signed in to change notification settings - Fork 56
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
HTML email using GMAILR - body is blank #57
Comments
Try the following which works for me test_email <- mime(
To = "leahwasser@gmail.com",
From = "neondataskills@gmail.com",
Subject = "this is just a gmailr test")
test_email <- html_body(test_email, "Can <b>you</b> hear me now?")
create_draft(test_email) |
Thank you @jimhester for the feedback.
My code:
What did I miss? |
Try installing the latest version from GitHub. # install.packages("devtools")
install_github("jimhester/gmailr") |
OK -- progress! I was able to create a draft once successfully. However, i have not been able to
both when i I triied to install the package crayon but when i do i get another odd output from both send and create draft as follows:
|
Hi @jimhester One other note. When I install from github and try to authenticate, it says it can't find OAuth2 in the browser. So this line gmail_auth("data-institute-email.json", scope = 'compose') Fails. When I install from cran I'm able to authenticate with no problem. |
Try installing from GitHub again, I have fixed a few things which should make this work better for you. You need to use the gmail_auth(secret_file = "data-institute-email.json", scope = 'compose') I am currently getting a Bounce error when trying to send the email, but the message still seems to go through... Creating a draft with |
Ok d5db6a7 now sends without Bouncing, so try updating again and let me know if it doesn't work. |
Thank you. Please tell me if am doing this wrong. I got an error on the install. So I uninstalled gmailr and made sure it was gone in my library dir on my mac. I then installed from github and got the following message / error (at the very bottom):
|
Sorry that was an inadvertent error, sorry for the confusion. It should now be fixed. |
Ok... it installed perfectly but i'm still getting the following error (it authenticates and then throws an error when i try to create draft or send_email.
the path there is where my packages are stored so is this error on my end? |
Something strange is going on. Does this happen if you start an entirely new session? You may want to try reinstalling the crayon package from CRAN as well. |
ok! Progress. Iyou are right - something was weird with my session. I restarted.
However, if i install from cran. run gmail_auth AND then install from github, i can send an html email successfully! it does ask me to authenticate a few other items (create draft, etc) when i use create_draft but then it works. Is there something there that is different in gmail_auth in the git version compared to the cran version? Thank you so much for working through this with me! |
@jimhester is there any way we can send whole html file by placing the directory? |
hi @jimhester - this is in response to your twitter suggestion. I am having a hard time getting
body_html to properly send email in r using
GMAILR
. I have tried numerous different approaches and the result is always the same - an email with no body content when i use html_body.I presume that I am doing something wrong however i can not figure out what that might be. I just installed GMAILR the other day. I am running R 3.2.3.
The next chunk returns a blank email and the $body slot in test_email is also blank
to send the email (this works fine)
Any suggestions that you have area greatly appreciated!
Leah
The text was updated successfully, but these errors were encountered: