Where I live, non-compete agreement are valid only if there is some kind of compensation.
Because this compensation is there to make up for the potential loss of not being able to work for competitors, it can be quite high. Like getting full pay for several years after termination of contract.
Of course, this is rarely mentionned except for the most sensitive jobs. Meaning that non-compete clauses are usually (but not always) meaningless.