It seems that the tendency of pet cats to wander where and when they will is not a new one.
According to Ask the Past, a method in use in the late 1400s involved rubbing butter on its nose and legs for three days running. The information comes from a 15th-Century French document called The Distaff Gospels, a collection of things known and shared by women of that era.
It is probably unsurprising that a French solution to a problem involves food, but it would seem to me that a much simpler method of keeping the furry little psychopathic mooches around would be to actually give them some. That plan has some definitely strong history behind it.