Not chili powder, but the red pepper powder. It gets on their "hands", up their nose, and in their mouths, and off they go to water to wash up.
Of course, it does not stop the two legged varmit from stealing. Years ago on a Sunday Morning, we saw a late modelled car pull over to the shoulder on the on coming lane, everyone jumped out in their Sunday best clothes and ran into the field corn by the Iowa highway. After we passed it, they emerged fromthe field with their arms full of corn, dumped it into the trunk and piled in and left the scene.
Good luck. Racoons will raid and ruin a whole field in one visit.