Open osos opened 6 years ago
New in version 3.6: encoding and errors were added.
... Sometimes python is real "fun" .. I'll have a look into this as soon as I'm back on a laptop.
Same issue here:
Traceback (most recent call last):
File "./decoder.py", line 305, in <module>
resolver.fill(parser)
File "./decoder.py", line 190, in fill
self._lookup(addresses)
File "./decoder.py", line 164, in _lookup
output = subprocess.check_output(cmd, encoding="utf-8")
File "/usr/lib/python3.5/subprocess.py", line 626, in check_output
**kwargs).stdout
File "/usr/lib/python3.5/subprocess.py", line 693, in run
with Popen(*popenargs, **kwargs) as process:
TypeError: __init__() got an unexpected keyword argument 'encoding'
python3 --version
Python 3.5.2
I "fixed" the issue by using python 2.7 by changing
#!/usr/bin/env python3
to
#!/usr/bin/env python
At the top of the script.
Works as-is for me with Python 3.6.5 on Windows.
Got this on Linuxmint 18.3:
Traceback (most recent call last):
File "../../EspArduinoExceptionDecoder/decoder.py", line 305, in <module>
resolver.fill(parser)
File "../../EspArduinoExceptionDecoder/decoder.py", line 190, in fill
self._lookup(addresses)
File "../../EspArduinoExceptionDecoder/decoder.py", line 164, in _lookup
output = subprocess.check_output(cmd, encoding="utf-8")
File "/usr/lib/python3.5/subprocess.py", line 626, in check_output
**kwargs).stdout
File "/usr/lib/python3.5/subprocess.py", line 693, in run
with Popen(*popenargs, **kwargs) as process:
TypeError: __init__() got an unexpected keyword argument 'encoding'
$ python3 --version
Python 3.5.2