themperek / cocotb-test

Unit testing for cocotb
BSD 2-Clause "Simplified" License
146 stars 72 forks source link

stdout does not have flush #225

Open alexforencich opened 1 year ago

alexforencich commented 1 year ago

When working on the long log line fix, I encountered an exception from this line:

https://github.com/themperek/cocotb-test/blob/4a5f1d2df3f677cd57ab2c3870b22db287382314/cocotb_test/simulator.py#L371

It seems that stdout is a StreamReader object, which does not have flush(). Not sure if this line should be removed, or if there is an alternative method for doing something equivalent.