class_docstr: This class is meant to mock FastAPI Request class that isn't pickle-able.
  
  If a user relies on FastAPI Request annotation, the Lightning framework
  patches the annotation before pickling and replace them right after.
  
  Finally, the FastAPI request is converted back to the _FastApiMockRequest
  before being delivered to the users.
  
  Example:
  
      from lightning.app import LightningFlow
      from fastapi import Request
      from lightning.app.api import Post
  
      class Flow(LightningFlow):
  
          def request(self, request: Request) -> OutputRequestModel:
              ...
  
          def configure_api(self):
              return [Post("/api/v1/request", self.request)]
code: def stream(self):
      raise NotImplementedError
  
imports: import asyncio
  import inspect
  import time
  from copy import deepcopy
  from dataclasses import dataclass
  from functools import wraps
  from multiprocessing import Queue
  from typing import Any, Callable, Dict, List, Optional
  from uuid import uuid4
  from fastapi import FastAPI, HTTPException, Request, status
  from lightning_utilities.core.apply_func import apply_to_collection
  from lightning.app.api.request_types import _APIRequest, _CommandRequest, _RequestResponse
  from lightning.app.utilities.app_helpers import Logger
label_desc: Use image node_id 6 for calling the _FastApiMockRequest obj's underlying member method code with example usage: obj.stream() without return types