idempotency based on script metadata