make proxy a bit more robust