Slightly hacky error handling as results are being polled from pseudo server which doesn't send error headers