Hi,

A couple of times I’ve had source-builder hang seemingly randomly, with the 
following Python backtrace:

Exception in thread _stderr[]:
Traceback (most recent call last):
  File "/usr/lib/python3.8/threading.py", line 932, in _bootstrap_inner
    self.run()
  File "/usr/lib/python3.8/threading.py", line 870, in run
    self._target(*self._args, **self._kwargs)
  File "/home/anders/work/rtems/rsb/source-builder/sb/execute.py", line 204, in 
_readthread
    data = data.decode(sys.stdout.encoding)
UnicodeDecodeError: 'utf-8' codec can't decode bytes in position 4094-4095: 
unexpected end of data

My guess is that since the loop in execute._readthread() is reading in fixed 
4096-byte chunks, occasionally the boundary will fall in the middle of an UTF-8 
code point, causing the decode call to throw an error. Since source-builder 
stops reading the file handle at that point, it will then deadlock the child 
process. Unfortunately, I haven’t yet been able to reliably trigger the issue. 
Usually, re-running the same build command succeeds.

Regards,
Anders
_______________________________________________
users mailing list
users@rtems.org
http://lists.rtems.org/mailman/listinfo/users

Reply via email to