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

Issue with login #46

Open
LukeCLindgren opened this issue Sep 12, 2017 · 8 comments
Open

Issue with login #46

LukeCLindgren opened this issue Sep 12, 2017 · 8 comments

Comments

@LukeCLindgren
Copy link

Pulling from the newest version of the repository (#41), I'm the code is raising a login error.

This is what I have written:
`from googlevoice import Voice
from googlevoice.util import input
import BeautifulSoup

username, password = "[email protected]", "xxxxxx"
......

def google_login(username, password):
voice = Voice()
client = voice.login(username, password)
print client
return client
`

However, I'm getting this error:
Traceback (most recent call last): File "E:/Jason Core/Boot.py", line 75, in <module> control() File "E:/Jason Core/Boot.py", line 70, in control logins = System_Logins.read_logins(basedir) File "E:\Jason Core\System_Logins.py", line 33, in read_logins gv = google_login(login_list[type_list.index(item)], password_list[type_list.index(item)]) File "E:\Jason Core\System_Logins.py", line 44, in google_login client = voice.login(username, password) File "C:\Python27\lib\site-packages\googlevoice\voice.py", line 94, in login raise LoginError

@gkuenning
Copy link
Contributor

pygooglevoice can be spotty about identifying particular login failures. However, since it's still working for me I suspect that the particular problem is related to your Google account.

I'd suggest a couple of things. First, go into your Google settings and choose the less-secure option for allowing apps to login. Second, do your early testing with the "gvoice" application that comes with pygooglevoice; that will eliminate the possibility that it's bugs in your own application. Once you can use gvoice to login and do something simple, you'll know you have the Google settings right and can return to your own app.

@andreawhitlock
Copy link

I have a similar login problem:

[andrea@darius ~]$ gvoice
Email address:[email protected]
Password:
Traceback (most recent call last):
File "/usr/bin/gvoice", line 79, in
login()
File "/usr/bin/gvoice", line 49, in login
voice.login(options.email,options.passwd)
File "build/bdist.linux-x86_64/egg/googlevoice/voice.py", line 72, in login
AttributeError: 'NoneType' object has no attribute 'group'

I've disabled two-factor authorization from my google account. I've enabled access for less secure apps. I've connected to GV on my server with a commandline browser and logged in successfully:

[andrea@darius ~]$ lynx https://voice.google.com

I'm not sure why gvoice is not logging me in.

@chris001
Copy link

chris001 commented Sep 19, 2017

@LukeCLindgren @andreawhitlock
Try visiting this URL to "unlock" your account for login from a "new device" (any device/machine which GV possibly hasn't gotten a login request from, ever, or not recently).
https://accounts.google.com/DisplayUnlockCaptcha
Post back and let us know if this fixes the login for you.

@LukeCLindgren
Copy link
Author

@chris001 this worked for me. Thanka!

@andreawhitlock
Copy link

It did not work:

[andrea@darius ~]$ lynx https://accounts.google.com/DisplayUnlockCaptcha
[andrea@darius ~]$ gvoice
Traceback (most recent call last):
File "/usr/bin/gvoice", line 79, in
login()
File "/usr/bin/gvoice", line 49, in login
voice.login(options.email,options.passwd)
File "build/bdist.linux-x86_64/egg/googlevoice/voice.py", line 72, in login
AttributeError: 'NoneType' object has no attribute 'group'

And since I can lynx to https://voice.google.com/messages from the command line on the same server and login fine, I don't think it's a setting with my google account.

@andreawhitlock
Copy link

I initially installed the package from the Fedora dnf command. Then I downloaded the master zip file from here when I had errors and installed the local package with easy_install. It must not have overlaid everything or things got half-baked. I used pip uninstall to uninstall pygooglevoice and reinstalled from the master zip downloaded from here (using pip install). It's working now that I have a clean install.

@rtaft
Copy link

rtaft commented May 1, 2018

same issue here, ever since I added 2 factor authentication. I use an app password to send emails from the same server, but gvoice is failing.

@chris001
Copy link

chris001 commented May 1, 2018

@rtaft
It looks like app password doesn't work with gvoice because gvoice isn't using IMAP and SMTP (you can send emails with app password on SMTP), it's using http, and app passwords apparently don't work over http.

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

5 participants