try pexpect