I have a Program which uses locale.getlocale(). But in a snap this function returns None. How can I fix this?