Reputation: 3
I'm trying to sync between python and google drive with the following details:
Authorized JavaScript origins: http://localhost:8080
Authorized redirect URIs: http://localhost:8080/
I copied the json file to the directory and ran this code:
from pydrive.auth import GoogleAuth
gauth = GoogleAuth()
gauth.LocalWebserverAuth()
and I got this error:
from oauth2client.locked_file import LockedFile
ImportError: No module named locked_file
Can you please help me?
Upvotes: 0
Views: 979
Reputation: 2097
Had the same issue.
It looks there was a change in the newest version of the oauth2client
, v2.0.0, which broke compatibility with the google-api-python-client
module, which now got fixed https://github.com/adrian-the-git/google-api-python-client/commit/2122d3c9b1aece94b64f6b85c6707a42cca8b093, so an upgrade of the google-api-python-client
restores compatibility and make everything working again:
$ pip install --upgrade git+https://github.com/google/google-api-python-client
Upvotes: 4