I know I change change the locale for an application using
import locale
locale.setlocale(locale.LC_ALL, '')
Documentation says default value for locale usually comes from LANG environment variable. However, on Windows platform, it seems to be different. Where does Python takes the default value for locale? Is there a way to change this default value for all my Python scripts?
The default system locale for a windows system can be set via the control panel. Python uses this default locale when you call
setlocale
with '' as the second argument. See here on how to change the default locale.It is the value you've set in Control Panel.