Fix "UnicodeDecodeError: 'utf-8' codec can't decode byte" when non-Latin chars are used in project path // Resolve #3481

This commit is contained in:
Ivan Kravets
2020-04-28 18:05:08 +03:00
parent 6146b58520
commit 5e4b4bbacd
3 changed files with 7 additions and 6 deletions

View File

@ -6,6 +6,11 @@ Release Notes
PlatformIO Core 4
-----------------
4.3.3 (2020-??-??)
~~~~~~~~~~~~~~~~~~
* Fixed "UnicodeDecodeError: 'utf-8' codec can't decode byte" when non-Latin chars are used in project path (`issue #3481 <https://github.com/platformio/platformio-core/issues/3481>`_)
4.3.2 (2020-04-28)
~~~~~~~~~~~~~~~~~~

2
docs

Submodule docs updated: bff1fc845b...256c255e89

View File

@ -20,7 +20,6 @@ from threading import Thread
from platformio import exception
from platformio.compat import (
PY2,
WINDOWS,
get_filesystem_encoding,
get_locale_encoding,
@ -31,10 +30,7 @@ from platformio.compat import (
class AsyncPipeBase(object):
def __init__(self):
self._fd_read, self._fd_write = os.pipe()
if PY2:
self._pipe_reader = os.fdopen(self._fd_read)
else:
self._pipe_reader = os.fdopen(self._fd_read, encoding="utf-8")
self._pipe_reader = os.fdopen(self._fd_read)
self._buffer = ""
self._thread = Thread(target=self.run)
self._thread.start()