(f)
r"""
    >>> import io
    >>> read_uint1(io.BytesIO(b'\xff'))
    255
r"""
    >>> import io
    >>> read_uint1(io.BytesIO(b'\xff'))
    255
r >>> import io >>> read_uint1 ( io . BytesIO ( b \ xff )) 255
def read_uint1(f):
    r"""
    >>> import io
    >>> read_uint1(io.BytesIO(b'\xff'))
    255
    """

    data = f.read(1)
    if data:
        return data[0]
    raise ValueError("not enough data in stream to read uint1")
def read_uint1 ( f ) : data = f . read ( 1 ) if data : return data [ 0 ] raise ValueError ( "not enough data in stream to read uint1" )