This will work only on Python 3

This line should be changed to:
```python
loc, _ = locale.getdefaultlocale()
```