Debug log for unreadable state files (#913)

This commit is contained in:
Adrian Sampson 2014-08-24 10:07:25 -07:00
parent b512a0ce37
commit 904baa6bc1
2 changed files with 7 additions and 1 deletions

View file

@ -65,7 +65,12 @@ def _open_state():
try:
with open(config['statefile'].as_filename()) as f:
return pickle.load(f)
except:
except Exception as exc:
# The `pickle` module can emit all sorts of exceptions during
# unpickling, including ImportError. We use a catch-all
# exception to avoid enumerating them all (the docs don't even have a
# full list!).
log.debug(u'state file could not be read: {0}'.format(exc))
return {}

View file

@ -12,6 +12,7 @@ Fixes:
* The :doc:`/plugins/lyrics` only strips featured artists and
parenthesized title suffixes if no lyrics for the original artist and
title were found.
* Fix a crash when reading some files with missing tags.
1.3.7 (August 22, 2014)