Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 1 of 1 for mp4 (0.12 sec)

  1. docs_src/custom_response/tutorial008.py

    from fastapi.responses import StreamingResponse
    
    some_file_path = "large-video-file.mp4"
    app = FastAPI()
    
    
    @app.get("/")
    def main():
        def iterfile():  # (1)
            with open(some_file_path, mode="rb") as file_like:  # (2)
                yield from file_like  # (3)
    
    Python
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Mon Jul 19 19:14:58 GMT 2021
    - 360 bytes
    - Viewed (0)
Back to top