add some more error messages, in case something went wrong

Should help to debug errors...

cc @FlorinPeter