Replies: 1 comment
-
I think you'd have to go without the FileResponse and use the lower level streaming API in order to block the code returning until the file is fully sent. So, not easily. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I want to do something like this:
The advantage of writing data to a temp file is that it doesn't need to be stored in memory and the client can request specific ranges of the file.
My example code doesn't work, because the temporary file is deleted before the client can request any data. Is there a good way of implementing this, where the file automatically gets deleted when the client closes the request?
Beta Was this translation helpful? Give feedback.
All reactions