convert websocket error to human-readable string