async def drain(self) -> None:
        """Flush the write buffer.

        The intended use is to write

          await w.write(data)
          await w.drain()
        """
        if self._protocol.transport is not None:
            await self._protocol._drain_helper()
Flush the write buffer.

        The intended use is to write

          await w.write(data)
          await w.drain()
        
lib/aiohttp/http_writer.py