[Scons-users] scons 3.0.1: 'ascii' codec can't decode

Tim Jenness tjenness at lsst.org
Tue Nov 28 12:02:10 EST 2017


That line came up the other day with a different bug. I was wondering why it wasn’t using `kid.get_text_contents()`.

> On Nov 28, 2017, at 08:26 , <mpac1234 at will-hier-weg.de> <mpac1234 at will-hier-weg.de> wrote:
> 
> 
> I do not know why or how, but it seems the binary content of files appears as a python string in SCons/engine/node/Python.py:136 and decoding this as ascii fails.
> Changing SCons/engine/Node/Python.py:135,136 from
> for kid in self.children(None):
>             contents = contents + kid.get_contents().decode()
> to
> for kid in self.children(None):
>             contents = contents + kid.get_contents().encode('hex').decode()
> makes the errors ('ascii' codec can't decode byte xxxx in position x: ordinal not in range(128)) disappear. But I have no idea if this is a valid fix or if it breaks anything else.
>  
> 
> _______________________________________________
> Scons-users mailing list
> Scons-users at scons.org
> https://imsva91-ctp.trendmicro.com:443/wis/clicktime/v1/query?url=https%3a%2f%2fpairlist4.pair.net%2fmailman%2flistinfo%2fscons%2dusers&umid=4DD1EB76-5F0C-A405-82E3-C262848FEB2B&auth=f95e8f518a5a1451e680168b3f9df426ddd6fc8e-ded3bf46fcf4237a27f3aaeff727822f03e7c624



More information about the Scons-users mailing list