docs: def copy(src, dst):
      """
      Copies a source file to a destination file or directory.
  
      Equivalent to "shutil.copy".
  
      Source and destination can also be binary opened file-like objects.
  
      Args:
          src (path-like object or file-like object): Source file.
          dst (path-like object or file-like object):
              Destination file or directory.
  
      Raises:
           IOError: Destination directory not found.
      """
      # Handles path-like objects and checks if storage
      src, src_is_storage = format_and_is_storage(src)
      dst, dst_is_storage = format_and_is_storage(dst)
  
      # Local files: Redirects to "shutil.copy"
      if not src_is_storage and not dst_is_storage:
          return shutil_copy(src, dst)
  
      with handle_os_exceptions():
          # Checks destination
          if not hasattr(dst, 'read'):
              try:
                  # If destination is directory: defines an output file inside it
                  if isdir(dst):
                      dst = join(dst, basename(src))
  
                  # Checks if destination dir exists
                  elif not isdir(dirname(dst)):
                      raise IOError("No such file or directory: '%s'" % dst)
  
              except ObjectPermissionError:
                  # Unable to check target directory due to missing read access,
                  # but do not raise to allow to write if possible
                  pass
  
          # Performs copy
          _copy(src, dst, src_is_storage, dst_is_storage)