fix up stream.py