GNU bug report logs -
#48129
28.0.50; Per file-handle (stdin, stdout and stderr) process-connection-type variable
Previous Next
Full log
Message #38 received at 48129 <at> debbugs.gnu.org (full text, mbox):
On 6/12/21 17:31, Eli Zaretskii wrote:
>> * if a stderr argument is not passed to make-process, then both stdin as
>> well as stdout in the subprocess are connected to pty devices.
>
> Indeed, I forgot that using :stderr with make-process automatically
> resets the process connection typ to use pipes for all the 3 standard
> handles. I guess there's some technical issue underlying that?
I guess you mean a technical issue in emacs and not in the OS, right?
cpython e.g. doesn't have this limitation. In cpython you can pass
one of the following values to each file handle (stdin, stdout, stderr)
in the subprocess module:
(see https://docs.python.org/3.10/library/subprocess.html#subprocess.Popen)
subprocess.DEVNULL
Special value that can be used as the stdin, stdout or stderr
argument to Popen and indicates that the special file os.devnull will be
used.
subprocess.PIPE
Special value that can be used as the stdin, stdout or stderr
argument to Popen and indicates that a pipe to the standard stream
should be opened. Most useful with Popen.communicate().
subprocess.STDOUT
Special value that can be used as the stderr argument to Popen and
indicates that standard error should go into the same handle as standard
output.
It is also possible to use
> an existing file descriptor (a positive integer), an existing file
object, and None.
If you want to assign a file handle to pty you have to pass a file
descriptor to one of the handles (stdin,stdout,stderr)
It would be nice if emacs were as flexible as cpython w.r.t. configuring
file handles for subprocesses.
> Because we had that restriction since day one. Perhaps using PTYs
> means that stderr must be redirected to the same device as stdout or
> something?
>
Diese E-Mail enthält vertrauliche und/oder rechtlich geschützte Informationen. Wenn Sie nicht der richtige Adressat sind oder diese E-Mail irrtümlich erhalten haben, informieren Sie bitte sofort den Absender und vernichten Sie diese Mail. Das unerlaubte Kopieren sowie die unbefugte Weitergabe dieser Mail ist nicht gestattet.
This e-mail may contain confidential and/or privileged information. If you are not the intended recipient (or have received this e-mail in error) please notify the sender immediately and destroy this e-mail. Any unauthorized copying, disclosure or distribution of the material in this e-mail is strictly prohibited.
IMS Nanofabrication GmbH FN: 208021 p, FB-Gericht: Wien; Sitz: Schreygasse 3, 1020, Vienna (Austria),Tel. +43 1 214 48 94; E-Mail: imsoffice <at> ims.co.at; DVR-Nr: 0374369; www.ims.co.at
This bug report was last modified 3 years and 342 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.