only clear cache if we're actually inserting new versions