I'm using pylint + pydev, with python 2.6. I have a module with just this line of code
from email import Message
Now when I try to run this module it runs fine. But pylint reports an error:
ID: E0611 No name 'Message' in module 'email'
Although it exists... Any idea why?
realise this is an old question, but the correct answer is that the older ways of invoking what you need, which use the "import hackery" that Richie describes, have long been deprecated (despite still appearing in many tutorials). If you use the new ways, you'll be writing better code and pylint
won't complain.
e.g.
from email import Message
from email import Header
from email.MIMEText import MIMEText
should be
from email.message import Message
from email.header import Header
from email.mime.text import MIMEText
etc.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With