Folks, I would like to know if there is an issue w/ wexpect.
Is this module working as expected?
things seem to work as expected in pexpect on linux
import wexpect
child = wexpect.spawn('cmd')
child.expect('>') #instantaneous response
child.sendline('python3')
child.expect('>') #this stays stuck here for 15 seconds before returning with success (pexpect is instantaneous)
child.sendline('import os')
child.expect('>') #instantaneous response
child.sendline('os.curdir')
child.expect('>') #instantaneous response
child.sendline()
child.expect('>') #raises TIMEOUT
child.before()
# Traceback (most recent call last):
#File "<stdin>", line 1, in <module>
#TypeError: 'str' object is not callable
#contrast this to pexpect: b">>> os.curdir
'.'
>>> os.curdir
'.'
>>> "
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…