From 3edf8d37b5f572b6a5bd4f27106c34600160fa75 Mon Sep 17 00:00:00 2001 From: Yusur Princeps Date: Sun, 10 Aug 2025 11:47:27 +0200 Subject: [PATCH] unfortunately, response body is still needed in full --- src/suou/sass.py | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/src/suou/sass.py b/src/suou/sass.py index 0b7477c..88b885f 100644 --- a/src/suou/sass.py +++ b/src/suou/sass.py @@ -134,11 +134,14 @@ class SassAsyncMiddleware(_MiddlewareFactory): ] }) + resp_body = b'' async for chunk in _read_file(file_path): - await send({ - 'type': 'http.response.body', - 'body': chunk - }) + resp_body += chunk + + await send({ + 'type': 'http.response.body', + 'body': resp_body + }) await self.app(scope, receive, send)