How Sse work with streaming?

Hi @all I’m working with sanic streaming channel as sse.
I have stream functions:

async def docker(request):
    async def sample_streaming_fn(response):
         await response.write(data=dumps(log))
         await asyncio.sleep(1)
    return stream(sample_streaming_fn, content_type='text/event-stream')

But it return data not in sse style. How can I solve this problem?