mirror of
https://github.com/beetbox/beets.git
synced 2025-12-06 08:39:17 +01:00
scrub: handle IOError
Mutagen can raise this error when trying to truncate a file.
This commit is contained in:
parent
b1ea90a724
commit
2f053b0ecd
2 changed files with 6 additions and 0 deletions
|
|
@ -108,6 +108,11 @@ def _scrub(path):
|
||||||
# remove them. In this case, we just remove all the tags.
|
# remove them. In this case, we just remove all the tags.
|
||||||
for tag in f.keys():
|
for tag in f.keys():
|
||||||
del f[tag]
|
del f[tag]
|
||||||
|
except IOError as exc:
|
||||||
|
log.error(u'could not scrub {0}: {1}'.format(
|
||||||
|
util.displayable_path(path),
|
||||||
|
exc,
|
||||||
|
))
|
||||||
f.save()
|
f.save()
|
||||||
|
|
||||||
# Automatically embed art into imported albums.
|
# Automatically embed art into imported albums.
|
||||||
|
|
|
||||||
|
|
@ -36,6 +36,7 @@ And some bug fixes:
|
||||||
Intzoglou.
|
Intzoglou.
|
||||||
* Fix an occasional crash in the :doc:`/plugins/beatport` when a length
|
* Fix an occasional crash in the :doc:`/plugins/beatport` when a length
|
||||||
field was missing from the API response. Thanks to Timothy Appnel.
|
field was missing from the API response. Thanks to Timothy Appnel.
|
||||||
|
* :doc:`/plugins/scrub`: Handle and log I/O errors.
|
||||||
|
|
||||||
|
|
||||||
1.2.0 (June 5, 2013)
|
1.2.0 (June 5, 2013)
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue