code: def list(self, path, depth=1):
          
          if not path.endswith('/'):
              path += '/'
  
          headers = {}
          if isinstance(depth, int) or depth == "infinity":
              headers['Depth'] = str(depth)
  
          res = self._make_dav_request('PROPFIND', path, headers=headers)
          # first one is always the root, remove it from listing
          if res:
              return res[1:]
          return None
docs: Returns the listing/contents of the given remote directory
  
          :param path: path to the remote directory
          :param depth: depth of the listing, integer or "infinity"
          :returns: directory listing
          :rtype: array of :class:`FileInfo` objects
          :raises: HTTPResponseError in case an HTTP error status was returned