def packRequest_pty_req(term, (rows, cols, xpixel, ypixel), modes):
    termPacked = common.NS(term)
    winSizePacked = struct.pack('>4L', cols, rows, xpixel, ypixel)
    modesPacked = common.NS(modes) # depend on the client packing modes
    return termPacked + winSizePacked + modesPacked
Pack a pty-req request so that it is suitable for sending.
dataset/ETHPy150Open nlloyd/SubliminalCollaborator/libs/twisted/conch/ssh/session.py/packRequest_pty_req