Catch errors when creating db client