Isn't this because they have anti-bacterial properties? So that you can preserve food and especially in hot climates you don't get food poisoning as easily?
Yup! I studied evolutionary psychology in college. Different seasonings helped make food safer to eat in hotter climates. My prof said “that's why if you leave a really salty piece of jerky under your bed, it's probably fine.”
Also explains why cultures up north typically didn't adapt a preference for spicy food as the cold allowed them to preserve food that way
That doesn't really make much sense since salted and pickled foods are eaten up north. The more logical explanation is that spicy food doesn't grow up north.
Maybe in hotter climates you have more problems with bacteria vs fungus / rot in colder climates? Another explanation is that spicy / hot food is popular because it forces you to drink more water. But it's all speculation on my part, never found any definitive answers.