pyinvoke / invoke

Pythonic task management & command execution.
http://pyinvoke.org
BSD 2-Clause "Simplified" License
4.31k stars 365 forks source link

EncodeWarning's when running on python >= 3.11 #985

Open rasjani opened 5 months ago

rasjani commented 5 months ago

If PYTHONWARNDEFAULTENCODING environment variable is set to true; following 2 warnings are printed to stderr:

/Users/rasjani/src/omat/diff-filter/venv/lib/python3.11/site-packages/invoke/runners.py:1674: EncodingWarning: UTF-8 Mode affects locale.getpreferredencoding(). Consider locale.getencoding() instead.
  encoding = locale.getpreferredencoding(False)
/Users/rasjani/src/omat/diff-filter/venv/lib/python3.11/site-packages/yamllint/config.py:41: EncodingWarning: 'encoding' argument not specified
  with open(file) as f: