Forum Archive

How to fix 'UnicodeDecodeError' (ascii codec can't decode byte 0xc2) error when installing module from StaSH

namm

I am trying to install this module: azure-mgmt-datafactory using StaSH, but I cannot install it successfully and it gives this error: 'ascii' codec can't decode byte 0xc2 in position 1488: ordinal not in range(128).

Any suggestions on how to fix this?

Edit: It seems I need to do export LC_ALL=C. Any way to do this in Pythonista?

Harwood

site-packages/stash/.stashrc can be used for exports.

As to the UnicodeDecodeError, take a look at https://github.com/ywangd/stash/pull/367.

shtek

very useful

why not merged yet?

it's utf8 everywhere, why stick to python 2

bennr01

@shtek said:

why not merged yet?

It is now merged.

it's utf8 everywhere, why stick to python 2

If your question is "why is StaSh still py2 and not yet py3?", then there are two reasons:
1. Large codebase, some of it using py2-only or outdated dependencIes (e.g.g git)
2. The person who did most of the current port to py3 finally understood that py3 is an abomination which needs to be fought until our very last breath

willwon155

@shtek Great info thanks for sharing I am a Technician in Dubai If you want to Repair any kind of printer or machinery items you can visit