[python-win32] win32pipe and buffer size

Tony Cappellini tony at tcapp.com
Fri Jul 15 17:59:54 CEST 2005


Hi

There is a pure-python version of expect called pExpect- use google to find 
it in sourceforge
It's not from Active State- but Active State is not such a big deal.

Message: 2
Date: Mon, 11 Jul 2005 17:41:24 +0200
From: Frank Guenther <xeoicq at netscape.net>
Subject: [python-win32] win32pipe and buffer size
To: python-win32 at python.org
Message-ID: <42D29324.2070307 at netscape.net>
Content-Type: text/plain; charset=ISO-8859-1; format=flowed

Hi All,

I try to automate a command line tool and have the problem that I can't
read the stdout-pipe.
I think the reason is the tool doesn't flush the pipe so  it is first
readable when the process was closed.
Can I set the buffer size of the stdout-pipe by win32pipe to force the
tool to write to the pipe?

Is there a possibility to use win32file to get a low-level access to the
pipes or some other solution to the problem?
I would be thankful for some hints and example code.

Has someone experiences with 'Excpect'-tools like ExcpectNT or Excpect
from ActiveState? Could this be an easy solution for my problem?

Ciao,
    Frank



More information about the Python-win32 mailing list