mirror of
https://github.com/beetbox/beets.git
synced 2025-12-10 02:22:25 +01:00
echonest_tempo: catch socket.error
This commit is contained in:
parent
69f2659410
commit
218f10a62d
2 changed files with 4 additions and 1 deletions
|
|
@ -22,6 +22,7 @@ from beets import ui
|
|||
from beets import config
|
||||
import pyechonest.config
|
||||
import pyechonest.song
|
||||
import socket
|
||||
|
||||
# Global logger.
|
||||
log = logging.getLogger('beets')
|
||||
|
|
@ -79,7 +80,7 @@ def get_tempo(artist, title):
|
|||
else:
|
||||
log.warn(u'echonest_tempo: {0}'.format(e.args[0][0]))
|
||||
return None
|
||||
except pyechonest.util.EchoNestIOError as e:
|
||||
except (pyechonest.util.EchoNestIOError, socket.error) as e:
|
||||
log.debug(u'echonest_tempo: IO error: {0}'.format(e))
|
||||
time.sleep(RETRY_INTERVAL)
|
||||
else:
|
||||
|
|
|
|||
|
|
@ -47,6 +47,8 @@ Other stuff:
|
|||
are missing all metadata.
|
||||
* :doc:`/plugins/mbcollection`: Show friendly, human-readable errors when
|
||||
MusicBrainz exceptions occur.
|
||||
* :doc:`/plugins/echonest_tempo`: Catch socket errors that are not handled by
|
||||
the Echo Nest library.
|
||||
|
||||
1.1b2 (February 16, 2013)
|
||||
-------------------------
|
||||
|
|
|
|||
Loading…
Reference in a new issue