Skip to content
This repository has been archived by the owner on Jan 14, 2022. It is now read-only.

Crashing on start #28

Closed
dis-aster opened this issue May 17, 2017 · 8 comments
Closed

Crashing on start #28

dis-aster opened this issue May 17, 2017 · 8 comments
Labels

Comments

@dis-aster
Copy link

Logging in... Logged in as m.........7k@gmail.com (Free).
Enter 'h' or 'help' if you need help.Traceback (most recent call last):
File "/home/maxim/bin/gpymusic", line 26, in
) else common.client.FreeClient()
AttributeError: 'NoneType' object has no attribute 'FreeClient'

@christopher-dG
Copy link
Owner

I can't reproduce this so I'm going to need more information. OS, Python version and gmusicapi version at least. It looks like you've installed in a somewhat non-standard way, so can you detail the steps you took to install the program?

@matteing
Copy link
Contributor

matteing commented May 17, 2017 via email

@matteing
Copy link
Contributor

matteing commented May 17, 2017 via email

@dis-aster
Copy link
Author

gpymusic installed as symlink:
~/bin/gpymusic -> /home/maxim/.local/share/gpymusic/src/main.py

OS:
Ubuntu 16.04
uname -a
Linux ENVY 4.10.2-041002-generic #201703120131 SMP Sun Mar 12 06:33:34 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux

Python:
3.5.2 virtualenv through pyenv

pip3 list:
Package Version


appdirs 1.4.3
beautifulsoup4 4.6.0
decorator 4.0.11
future 0.16.0
gmusicapi 10.1.2
gpsoauth 0.4.1
httplib2 0.10.3
MechanicalSoup 0.7.0
mock 2.0.0
mutagen 1.37
oauth2client 4.1.0
pbr 3.0.0
pip 9.0.1
proboscis 1.2.6.0
protobuf 3.3.0
pyasn1 0.2.3
pyasn1-modules 0.0.8
pycryptodomex 3.4.5
python-dateutil 2.6.0
requests 2.14.2
rsa 3.4.2
setuptools 20.10.1
six 1.10.0
validictory 1.1.1

gpmusic$ git pull
Already up-to-date.

@christopher-dG
Copy link
Owner

@ftxrc thanks! I wasn't able to "properly" cherry pick since there were some other changes in bin/gpymusic but either way it's fixed.

@dis-aster
Copy link
Author

unfortunately with fix ftxrc@720e7fa i get this exception:

Logging in... Logged in as m********7k@gmail.com (Free).
Enter 'h' or 'help' if you need help./home/maxim/.pyenv/versions/gpmusic/lib/python3.5/site-packages/oauth2client/_helpers.py:255: UserWarning: Cannot access /home/maxim/.local/share/gmusicapi/oauth.cred: No such file or directory
warnings.warn(_MISSING_FILE_MESSAGE.format(filename))
2017-05-18 00:20:17,768 - gmusicapi.Musicmanager2 (musicmanager:186) [WARNING]: could not retriGenerating your library...Traceback (most recent call last):
Could not find library file.                                  File "/home/maxim/bin/gpymusic", line 27, in <module>
) else client.FreeClient()
File "/home/maxim/.local/share/gpymusic/src/client.py", line 311, in __init__
self.gen_library()
File "/home/maxim/.local/share/gpymusic/src/client.py", line 347, in gen_library
for song in self.mm.get_uploaded_songs():
File "/home/maxim/.pyenv/versions/gpmusic/lib/python3.5/site-packages/gmusicapi/clients/musicmanager.py", line 287, in get_uploaded_songs
to_return = [song for chunk in to_return for song in chunk]
File "/home/maxim/.pyenv/versions/gpmusic/lib/python3.5/site-packages/gmusicapi/clients/musicmanager.py", line 287, in <listcomp>
to_return = [song for chunk in to_return for song in chunk]
File "/home/maxim/.pyenv/versions/gpmusic/lib/python3.5/site-packages/gmusicapi/clients/musicmanager.py", line 337, in _get_all_songs
export_type)
File "/home/maxim/.pyenv/versions/gpmusic/lib/python3.5/site-packages/gmusicapi/clients/shared.py", line 84, in _make_call
return protocol.perform(self.session, self.validate, *args, **kwargs)
File "/home/maxim/.pyenv/versions/gpmusic/lib/python3.5/site-packages/gmusicapi/protocol/shared.py", line 207, in perform
req_kwargs = cls.build_request(*args, **kwargs)
File "/home/maxim/.pyenv/versions/gpmusic/lib/python3.5/site-packages/gmusicapi/protocol/shared.py", line 89, in build_request
val = val(*args, **kwargs)
File "<decorator-gen-68>", line 2, in dynamic_data
File "/home/maxim/.pyenv/versions/gpmusic/lib/python3.5/site-packages/gmusicapi/protocol/musicmanager.py", line 69, in pb
msg = f(*args, **kwargs)
File "/home/maxim/.pyenv/versions/gpmusic/lib/python3.5/site-packages/gmusicapi/protocol/musicmanager.py", line 652, in dynamic_data
msg.client_id = client_id
TypeError: None has type NoneType, but expected one of: bytes, unicode

@dis-aster
Copy link
Author

sorry. my mistake. Missed the launch of the script oauth_login.py
now all fine!

@christopher-dG
Copy link
Owner

Yeah, that's still a problem though -- even if you haven't run the scripts it should let you know and exit gracefully. Thanks for bringing this up!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

3 participants