[Scons-users] SCons 3.0.0 and Util.py

Bassem Girgis brgirgis at gmail.com
Tue Oct 3 17:46:47 EDT 2017


Hi All,

I'm trying to migrate to SCons 3.0.0 to use python 3.6 as my only python
installation. In doing so I ran into the issue shown below. It lookd like
the to_str() function in Util.py is not expecting None and it got one. From
my end, it looks like a directory install is what caused it. Editing the
to_str() function to return empty str in that case solved the issue.
However, I'm not sure if the issue is rather in the Install() builder that
returned a None from the executer.

Install directory: "to/project/runtime/linx64" as
"to/install/linx64/lib/linx64"
--------------> None
scons: *** [to/install/linx64/lib/linx64] TypeError : decoding to str: need
a bytes-like object, NoneType found
Traceback (most recent call last):
  File "/usr/lib/scons-3.0.0/SCons/Taskmaster.py", line 255, in execute
    self.targets[0].build()
  File "/usr/lib/scons-3.0.0/SCons/Node/__init__.py", line 750, in build
    self.get_executor()(self, **kw)
  File "/usr/lib/scons-3.0.0/SCons/Executor.py", line 396, in __call__
    return _do_execute_map[self._do_execute](self, target, kw)
  File "/usr/lib/scons-3.0.0/SCons/Executor.py", line 127, in
execute_action_list
    status = act(*args, **kw)
  File "/usr/lib/scons-3.0.0/SCons/Action.py", line 709, in __call__
    stat = self.execute(target, source, env, executor=executor)
  File "/usr/lib/scons-3.0.0/SCons/Action.py", line 1207, in execute
    result = SCons.Errors.convert_to_BuildError(result, exc_info)
  File "/usr/lib/scons-3.0.0/SCons/Errors.py", line 203, in
convert_to_BuildError
    exc_info=exc_info)
  File "/usr/lib/scons-3.0.0/SCons/Errors.py", line 98, in __init__
    self.errstr = SCons.Util.to_str(errstr)
  File "/usr/lib/scons-3.0.0/SCons/Util.py", line 1624, in to_str
    return str (s, 'utf-8')
TypeError: decoding to str: need a bytes-like object, NoneType found
scons: building terminated because of errors.


Bassem Girgis, PhD

Email: brgirgis at gmail.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://pairlist4.pair.net/pipermail/scons-users/attachments/20171003/01c50082/attachment.html>


More information about the Scons-users mailing list