mopidy / mopidy-soundcloud

Mopidy extension for playing music from SoundCloud
https://mopidy.com/ext/soundcloud/
MIT License
185 stars 59 forks source link

Can't get Soundcloud connection at the moment (status code 401) #71

Closed mrvanes closed 6 years ago

mrvanes commented 8 years ago

It seems Soundcloud returns a 401 on authentication request but the code isn't prepared to handle the answer (attribute response is missing). I'm quite sure the auth_token I use is correct.

ERROR    Got un-handled exception from SoundCloudBackend
Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/mopidy/commands.py", line 239, in _actor_error_handling
    yield
  File "/usr/lib/python2.7/dist-packages/mopidy/commands.py", line 380, in start_backends
    config=config, audio=audio).proxy()
  File "/usr/lib/python2.7/dist-packages/pykka/actor.py", line 94, in start
    obj = cls(*args, **kwargs)
  File "/usr/lib/python2.7/dist-packages/mopidy_soundcloud/actor.py", line 21, in __init__
    self.remote = SoundCloudClient(config['soundcloud'])
  File "/usr/lib/python2.7/dist-packages/mopidy_soundcloud/soundcloud.py", line 80, in __init__
    if err.response is not None and err.response.status_code == 401:
AttributeError: 'ConnectionError' object has no attribute 'response'
mrvanes commented 8 years ago

Seems fixed now, probably hickup @ Soundcloud side?

jodal commented 8 years ago

Probably, but leaving this open as we should probably replace err.response is not None with getattr(err, 'response', None) is not None or similar.

kingosticks commented 6 years ago

The error handling is improved in #100, I believe this is now fixed.