Version 30 of Expect for Windows

Updated 2002-12-04 13:05:44

People want Expect for Microsoft Windows.

Aspects of it exist. Gordon Chaffee ported 5.21r1b1 to WindowsNT. Binary and source are available at [L1 ], and also present in (? and MyrmecoX (?), but not TclKit (for want of stubsication?). This corresponds to Tcl version 8.?3?.


During the early winter 2001-2002, Telindustrie LLC briefly supported David Gravereaux's work to port 8.4 to Windows. Davy's much the world's most knowledgeable person about what this will involve. He has definite plans and designs for completion of this task, but no resources and therefore no schedule. He writes, "There is a *somewhat* working 8.4 ready binary of Expect for windows @

   http://sf.net/project/showfiles.php?group_id=13179 . It's far from
   done. Using spawn with the -open option one can 'expect' on an already
   open channel, such as a socket or a serial port. The 'slave driver'
   aspect of spawn is where all the deep black magic is. The mojo isn't
   yet complete."

The windows specific code is already in the official repository off on a branch [L2 ]

With some support, this could be completed as Davy can only do so much as a hobby.


There are lots of ways this could go. Perl (and Python?) people might help out with Expect, and Win* expertise perhaps would be part of the package. Also interesting is a comp.lang.tcl exchange [L3 ] between Jiang Wu and Jeffrey Hobbs; note mention of how more of Expect might move into the Tcl core.

Andreas Kupries says [2001-sep-20] that Expect works fine under Cygwin as long as what you're expect'ing upon is a cygwin application. It can't work with normal/native Win32 console applications.

[Why and how it doesn't work for Win95. Problems with interact.] [Experience with Win2000.] [ Pure-Tcl telnet available--this sometimes suffices.]

[Expect 5.25/Tcl 7.6 for Japanese.] [5.31/8.2 as source.]

[ Tony Summerfelt's been mostly successful with Expect under Win2000.]


Is there a need for a trap to receive the "signal" when Expect is used as a Windows service? [L4 ]

IMO, No. The windows model provides this and the "shell" being used for the service control should get "going down" notices and hopefully "do the right thing". If expect.exe knows nothing for being a windows service, for which it shouldn't being a CLI shell, one should build a shell with all the needed service parts to get the notifications they need. See tclsvc - Tcl as an NT Service -- DG


[ CL intends to explain four reasons why many people who think they need Expect do not need Expect, for Windows in particular.]


Category Expect