Welcome, Guest: Register On Nairaland / LOGIN! / Trending / Recent / New
Stats: 3,194,366 members, 7,954,485 topics. Date: Friday, 20 September 2024 at 08:08 PM

Django Get Attributeerror: Str Object - Programming - Nairaland

Nairaland Forum / Science/Technology / Programming / Django Get Attributeerror: Str Object (302 Views)

Tutorial: Object Oriented Programming Paradigm For Beginners in Python / I Need Help In Object Oriented Programming / Let's Build A Simple Blog With Python(django) (2) (3) (4)

(1) (Reply)

Django Get Attributeerror: Str Object by syluck(m): 5:12pm On Mar 20, 2021
 File "/Users/aureliendebord/Python/myapp/app/utils.py", line 76, in password_mail
mail = Mail(from_email, subject, to_email, content)
File "/Users/aureliendebord/Python/myapp/myvenv/lib/python3.6/site-packages/sendgrid/helpers/mail/mail.py", line 31, in __init__
personalization.add_to(to_email)
File "/Users/aureliendebord/Python/myapp/myvenv/lib/python3.6/site-packages/sendgrid/helpers/mail/mail.py", line 523, in add_to
self._tos.append(email.get())
AttributeError: 'str' object has no attribute 'get'



my problem is at the bolded...

pls help
Re: Django Get Attributeerror: Str Object by Karleb(m): 5:20pm On Mar 20, 2021
From what I see, the error is coming from email.get(). What do you intend to get from email variable and why?
Re: Django Get Attributeerror: Str Object by syluck(m): 8:39pm On Mar 21, 2021
Karleb:
From what I see, the error is coming from email.get(). What do you intend to get from email variable and why?

Hey, bro thanks for your input.

I've rectified the issue.

(1) (Reply)

The Vicsad Academy / Apply To Participate In The Upcoming Health Meets Tech Pan African Hackathon / Google Voice Number Available

(Go Up)

Sections: politics (1) business autos (1) jobs (1) career education (1) romance computers phones travel sports fashion health
religion celebs tv-movies music-radio literature webmasters programming techmarket

Links: (1) (2) (3) (4) (5) (6) (7) (8) (9) (10)

Nairaland - Copyright © 2005 - 2024 Oluwaseun Osewa. All rights reserved. See How To Advertise. 6
Disclaimer: Every Nairaland member is solely responsible for anything that he/she posts or uploads on Nairaland.