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

googleapiclient :: missing module #12

Closed
vintaclectic opened this issue Dec 5, 2018 · 13 comments
Closed

googleapiclient :: missing module #12

vintaclectic opened this issue Dec 5, 2018 · 13 comments

Comments

@vintaclectic
Copy link

Traceback (most recent call last):
File "uds.py", line 3, in
from googleapiclient.discovery import build
ModuleNotFoundError: No module named 'googleapiclient'
Error in sys.excepthook:
Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/apport_python_hook.py", line 63, in apport_excepthook
from apport.fileutils import likely_packaged, get_recent_crashes
File "/usr/lib/python3/dist-packages/apport/init.py", line 5, in
from apport.report import Report
File "/usr/lib/python3/dist-packages/apport/report.py", line 30, in
import apport.fileutils
File "/usr/lib/python3/dist-packages/apport/fileutils.py", line 23, in
from apport.packaging_impl import impl as packaging
File "/usr/lib/python3/dist-packages/apport/packaging_impl.py", line 23, in
import apt
File "/usr/lib/python3/dist-packages/apt/init.py", line 23, in
import apt_pkg
ModuleNotFoundError: No module named 'apt_pkg'

Original exception was:
Traceback (most recent call last):
File "uds.py", line 3, in
from googleapiclient.discovery import build
ModuleNotFoundError: No module named 'googleapiclient'

Tried every trick in the books, even in your past issues and any stack overflow answers to similar issues to no avail. :/

@vintaclectic vintaclectic changed the title invalid syntax error upon first run googleapiclient :: missing module Dec 5, 2018
@stewartmcgown
Copy link
Owner

Not good! Did you install requirements?

@vintaclectic
Copy link
Author

Yes, requirements were installed immediately after cloning and entering repo.

@vintaclectic
Copy link
Author

json added to directory as client_secret.json too

@vintaclectic
Copy link
Author

Actually, somehow got passed it and to point where google login screen popups up. I go to login to my account, nothing happens thereafter. I have 2-step auth, does that cause a problem here? In fact, when I enter email/password I'm not even receiving any text notification for a code as if its not even posting data properly. Any idea?

@stewartmcgown
Copy link
Owner

any problems that you're having with the actual Google authentication system might be better directed at the team themselves: https://github.com/googleapis/oauth2client

have you got any screenshots or additional program output to show?

@sirpilsofd
Copy link

Having a similar issue as stated in the original post.
Traceback (most recent call last):
File "uds.py", line 3, in
from googleapiclient.discovery import build
ModuleNotFoundError: No module named 'googleapiclient'
OS: Ubuntu 16.04
Using Python 3.6 and all of the requirements have been installed and the JSON has been added to the uds directory as 'client_secret.json

Not sure what to try next

@stewartmcgown
Copy link
Owner

does this fix

pip install --upgrade google-api-python-client

@vintaclectic
Copy link
Author

No, the issue is that you are having a python program have to connect to a google account such that if someone, like myself, has two-factor authentication setup with their google account then it becomes impossible to sign in in order to use this program at all...have you ever tried signing into anything via cli where two-factor is required...haha, it's impossible unless you can somehow find a way for your browser to open login page then somehow take you back into the terminal...

@glotchimo
Copy link

glotchimo commented Dec 7, 2018

@stewartmcgown oauth2client is deprecated (for many reasons, explained on that page). We should implement the new google-auth which would enable users to utilize the more secure API service accounts (and the auth files that come with) rather than the old OAuth2 single-token method.

@78Alpha
Copy link
Contributor

78Alpha commented Feb 21, 2019

How much under the hood tampering would be needed?

@aiyolo
Copy link

aiyolo commented May 16, 2019

I just have the same error, is there any solution now?

@j0nasjuul
Copy link

I had this same issue. Switching python3 to be the default python version solved the problem.

@sammyhass
Copy link
Collaborator

I had this same issue. Switching python3 to be the default python version solved the problem.

Ensure you are using python3 not python2 as your default version

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

8 participants