declension / squeeze-alexa

Squeezebox integration for Amazon Alexa
GNU General Public License v3.0
59 stars 20 forks source link

TypeError if asking for what's playing on title with no artists #94

Closed declension closed 5 years ago

declension commented 5 years ago

Steps

Expected

Nothing is playing or something similar

Actual

Oh Dear: TypeError: NoneType Object is not iterable

Traceback (most recent call last):
File "/var/task/handler.py", line 44, in lambda_handler
return sqa.handle(event, context)
File "/var/task/squeezealexa/main.py", line 60, in handle
return super(SqueezeAlexa, self).handle(event, context)
File "/var/task/squeezealexa/alexa/handlers.py", line 49, in handle
return self.on_intent(request, session)
File "/var/task/squeezealexa/main.py", line 85, in on_intent
return intent_handler(self, intent, session, pid=pid)
File "/var/task/squeezealexa/main.py", line 115, in now_playing
artist = human_join(people_from(details))
File "/var/task/squeezealexa/utils.py", line 37, in human_join
items = list(filter(None, items))
TypeError: 'NoneType' object is not iterable