I'm migrating user-uploaded files from a local filesystem to MinIO (an S3-compatible file server). I can't use FileResponse because I get back a filehandle or a bytes, and I'd have to write it to a temporary file to use FileResponse.I'm also exploring presigned URLs to have the browser fetch the file, but right now I want to serve it server-side. What Pyramid response args should I use, and how should I stream the content? I looked at the source of FileResponse, and it creates an 'app_iter' object using 'environ["wsgi.file_wrapper"]'. Do I have to do all that? Or can I just do 'body_file=result["body"]', which is the filehandle and has a 'read' method. What is 'wsgi.file_wrapper' anyway?
-- Mike Orr <sluggos...@gmail.com> -- You received this message because you are subscribed to the Google Groups "pylons-discuss" group. To unsubscribe from this group and stop receiving emails from it, send an email to pylons-discuss+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/pylons-discuss/CAH9f%3Duo5fd-y9BdB0t5GgFmykNRUOxrAr7V0FXK6hOu8uZrUsA%40mail.gmail.com.