Skip to content
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

Message instance has no attribute 'body' #77

Open
mridah opened this issue Dec 26, 2016 · 1 comment
Open

Message instance has no attribute 'body' #77

mridah opened this issue Dec 26, 2016 · 1 comment

Comments

@mridah
Copy link

mridah commented Dec 26, 2016

I'm trying to fetch the body of an email using

mails = g.inbox().mail(sender="sender@senderemail.com")
mail = mails[0].fetch()
print mail['subject']
print mail.body

Here, I am able to get properties like subject, Received, etc. but when printing body, I get this error :

Message instance has no attribute 'body'

This is the data I'm getting :

From nobody Mon Dec 26 16:42:46 2016
Delivered-To: someone@examplemail.com
Received: by 10.28.211.66 with SMTP id ferf98er9fef9fr;
.
.
.
X-Source-Dir: erferfefefrref:/public_html
X-CMAE-Envelope: grtgrtgrtgrtgrt......

This is the message body
@mridah
Copy link
Author

mridah commented Dec 27, 2016

@charlierguo please check this

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant