Better failure handling
This commit is contained in:
@@ -399,7 +399,6 @@ class LibremsonicApp(Gtk.Application):
|
||||
# Do this the old fashioned way so that we can have access to ``reset``
|
||||
# in the callback.
|
||||
def do_play_song(song: Child):
|
||||
# TODO force mp3 while getting chromecast working.
|
||||
uri, stream = CacheManager.get_song_filename_or_stream(
|
||||
song,
|
||||
format='mp3',
|
||||
|
@@ -90,7 +90,7 @@ class Server:
|
||||
result = requests.get(url, params=params)
|
||||
# TODO make better
|
||||
if result.status_code != 200:
|
||||
raise Exception(f'Fail! {result.status_code}')
|
||||
raise Exception(f'[FAIL] get: {url} status={result.status_code}')
|
||||
|
||||
print(f'[FINISH] get: {url}')
|
||||
return result
|
||||
|
Reference in New Issue
Block a user