Implement logging of errors during plugin processing. Fixes #24.