added liking by double tapping album art
add exception handling to update.py, prepping for handling script
This commit is contained in:
@@ -2,6 +2,8 @@ import urllib
|
||||
from urllib.request import urlopen
|
||||
from zipfile import ZipFile
|
||||
from io import BytesIO
|
||||
from spotipy import exceptions as SpotipyExceptions
|
||||
from requests import exceptions as RequestsExceptions
|
||||
|
||||
while True:
|
||||
try:
|
||||
@@ -16,4 +18,8 @@ try:
|
||||
except urllib.error.HTTPError:
|
||||
pass
|
||||
|
||||
exec(open('spotifycontroller.py').read())
|
||||
try:
|
||||
exec(open('spotifycontroller.py').read())
|
||||
except (RequestsExceptions.HTTPError, SpotipyExceptions.SpotifyException):
|
||||
print("An error has ocurred, saving and reestablishing application now.")
|
||||
exec(open('spotifycontroller.py').read())
|
||||
Reference in New Issue
Block a user