﻿id	summary	reporter	owner	description	type	status	component	version	severity	resolution	keywords	cc	stage	has_patch	needs_docs	needs_tests	needs_better_patch	easy	ui_ux
34342	The test async_client is not consuming async StreamingResponse generators properly	Alexandre Spaeth	Alexandre Spaeth	"It seems that the way the `async_client` behaves with `StreamingResponse` makes it not play nicely with the fixes done in 4.2 to support async generators.

I think the issue is in `closing_iterator_wrapper`: we are naively calling `sync_to_async` on it, but I don’t believe this is possible with a proper async generator.

Here I tried to write a test to reproduce the issue:
https://github.com/Alexerson/django/commit/b05e524bfadfb0d553438d0375bad0009439fade

Looking at the codebase, I’m also believing that there are other parts that might break, for instance `assertContains` seems to expect a well behaved sync generator."	Bug	closed	Testing framework	4.2	Release blocker	fixed	async		Ready for checkin	1	0	0	0	0	0
