-BEGIN PGP SIGNED MESSAGE-
Hash: RIPEMD160
On 2011.07.15 07:02 PM, Pedro Abranches wrote:
> Now, if you're using your python script in some shell script you
> might have to store the output in some variable, like this:
>
> $ var=`python -c 'import sys; print sys.stdout.encoding; print
> u
I've used the code below successfully to deal with such a problem when
outputting filenames. Python2x3 is at
http://stromberg.dnsalias.org/svn/python2x3/ , but here it's just being used
to convert Python 3.x's byte strings to strings (to eliminate the b''
stuff), while on 2.x it's an identity func