pass error from stream

stream will not emit end when emit error

You can review the testcase, it will not emit task_err/err using the origin code.