Here’s a script I put on a button:
from java.util import Locale
print Locale.getDefault().getCountry()
print Locale.getDefault().getLanguage()
The output when I’m in en_CA is
CA
en
You’ll find more methods you can call on Locale.getDefault() at the Java docs for Locale.