Avoid headers errors in stream.py