Catch all exceptions when writing files during import

Import should not abort when an exception (other then IOError) was raised. This
is particularly useful for plugins that want to prevent beets from writing
files [1].

`except` code was copied from `ui.commands.write_items`.

[1]: https://github.com/geigerzaehler/beets-check/blob/master/beetsplug/check.py#L74