RobbieClarken / youtube-channel-to-playlist

Add all videos from a YouTube channel to a playlist
MIT License
30 stars 3 forks source link

KeyError: '_module' #4

Open nicholsons08 opened 5 years ago

nicholsons08 commented 5 years ago

hi, I did the following to setup Installed Python 3.7.2 Ran pip install --upgrade pip Ran install python-git Ran pip install git+https://github.com/RobbieClarken/youtube-channel-to-playlist created Project Google Cloud Console Enabled Youtube Data API Created Credentials for Other client_secrets.json { "installed":{ "client_id":"xxxxxxxxxxxx-xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx.apps.googleusercontent.com", "project_id":"sn-youtube-playlist-xxxxxx", "auth_uri":"https://accounts.google.com/o/oauth2/auth", "token_uri":"https://oauth2.googleapis.com/token", "auth_provider_x509_cert_url":"https://www.googleapis.com/oauth2/v1/certs", "client_secret":"xxxxxxxxxxxxxxxxxxxxxxxx", "redirect_uris":["urn:ietf:wg:oauth:2.0:oob","http://localhost"] } } channel_to_playlist --secrets client_secrets.json UC9ULRTHvszrMpy3kDT-KDIQ PLvc6ZvMQl_lzqOMrp42Wk0hU0ib92Jwxe

Traceback (most recent call last): File "C:\Program Files\Python37\Scripts\channel_to_playlist-script.py", line 11, in load_entry_point('YouTubeChannelToPlaylist==3.0.0', 'console_scripts', 'channel_to_playlist')() File "c:\program files\python37\lib\site-packages\channel_to_playlist.py", line 149, in main youtube = get_authenticated_service(args) File "c:\program files\python37\lib\site-packages\channel_to_playlist.py", line 44, in get_authenticated_service credentials = storage.get() File "c:\program files\python37\lib\site-packages\oauth2client\client.py", line 407, in get return self.locked_get() File "c:\program files\python37\lib\site-packages\oauth2client\file.py", line 54, in locked_get credentials = client.Credentials.new_from_json(content) File "c:\program files\python37\lib\site-packages\oauth2client\client.py", line 302, in new_from_json module_name = data['_module'] KeyError: '_module'

nicholsons08 commented 5 years ago

Also when I add the parameter --secrets client_secrets.json I get an error saying that it can't find the file .channel_to_playlist-oauth2-credentials.json. I then rename client_secrets.json to .channel_to_playlist-oauth2-credentials.json. At this point I get the error above.

TomasPP commented 5 years ago

See #5 for workaround.