def from_int(arg: str, length: int=-1) ->bytes:
    """
    Transform a integer string into a bytearray of a given length.

    :return: a bytearray
    """
    narg = int(arg)
    barg = narg.to_bytes(length, 'big')
    return barg
