catch errors while running server requests