fsspec/implementations/http.py
def read(self, length=-1):
        """Read bytes from file

        Parameters
        ----------
        length: int
            Read up to this many bytes. If negative, read all content to end of
            file. If the server has not supplied the filesize, attempting to
            read only part of the data will raise a ValueError.
        """
        if (
            (length < 0 and self.loc == 0)  # explicit read all
            # but not when the size is known and fits into a block anyways
            and not (self.size is not None and self.size <= self.blocksize)
        ):
            self._fetch_all()
        if self.size is None:
            if length < 0:
                self._fetch_all()
        else:
            length = min(self.size - self.loc, length)
        return super().read(length)
Read bytes from file

        Parameters
        ----------
        length: int
            Read up to this many bytes. If negative, read all content to end of
            file. If the server has not supplied the filesize, attempting to
            read only part of the data will raise a ValueError.
        
Read bytes from file
Parameters

int
Read up to this many bytes. If negative, read all content to end of
file. If the server has not supplied the filesize, attempting to
read only part of the data will raise a ValueError.
Read bytes from file Parameters int Read up to this many bytes . If negative read all content to end of file . If the server has not supplied the filesize attempting to read only part of the data will raise a ValueError .
def read(self, length=-1):
        if (
            (length < 0 and self.loc == 0)  
            and not (self.size is not None and self.size <= self.blocksize)
        ):
            self._fetch_all()
        if self.size is None:
            if length < 0:
                self._fetch_all()
        else:
            length = min(self.size - self.loc, length)
        return super().read(length)
def read ( self , length = - 1 ) : if ( ( length < 0 and self . loc == 0 ) and not ( self . size is not None and self . size <= self . blocksize ) ) : self . _fetch_all ( ) if self . size is None : if length < 0 : self . _fetch_all ( ) else : length = min ( self . size - self . loc , length ) return super ( ) . read ( length )
Read bytes from file
Parameters
Read bytes from file Parameters
"""Read bytes from file

        Parameters
        ----------
        length: int
            Read up to this many bytes. If negative, read all content to end of
            file. If the server has not supplied the filesize, attempting to
            read only part of the data will raise a ValueError.
        """ # explicit read all # but not when the size is known and fits into a block anyways
self
length