Better error handling

see #134