Partition functions that repel perfect-powers