Force writing to happen on main thread since that's where the stream is scheduled