diff --git a/project/README.md b/project/README.md index a107ad1b..cd7448e3 100644 --- a/project/README.md +++ b/project/README.md @@ -16,4 +16,16 @@ export LANG=en_US.UTF-8 export LANGUAGE=en_US.UTF-8 ``` +To verify the effect, you can run the following command end check that it outputs 'utf-8' +```python +> python -c 'import locale; print(locale.getpreferredencoding())' +utf-8 +``` + You can find more details in this [article](https://perlgeek.de/en/article/set-up-a-clean-utf8-environment). + +If this doesn't work, you can explicitly specify the encoding when opening files: +```python +with open(filename, 'r', encoding="utf-8") as file: + ... +```