Add timeout to callExternalScript