From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Jim Porter Newsgroups: gmane.emacs.bugs Subject: bug#56025: [WIP PATCH] 29.0.50; em-extpipe-test-2 times out on EMBA and Cygwin Date: Sun, 17 Jul 2022 22:26:36 -0700 Message-ID: <6725161c-1d45-8ded-5d75-aa1a74c9b3ed@gmail.com> References: <8e21db9c-0100-998e-f280-81304e7ff61a@cornell.edu> <040b3a36-459b-a94d-f879-7f45aac50bda@cornell.edu> <83sfnud26o.fsf@gnu.org> <96e47ba7-efaa-b6df-dd98-60f09068e68c@gmail.com> <874k097lbh.fsf@melete.silentflame.com> <8735frmjrr.fsf@athena.silentflame.com> <4676f52c-4758-38df-f0f4-dbcb5d848c1b@gmail.com> <8735fr2kq6.fsf@melete.silentflame.com> <10cf6a90-f86a-b0df-4dc2-c258b7494158@gmail.com> <18e79c02-3a2a-77d1-3798-33711f52d6b9@cornell.edu> <19c66901-2eeb-1f40-17a4-4ed54827e065@gmail.com> <5990de80-63a5-ac9b-1a11-c814aa9e38f2@gmail.com> <3779ea08-f481-5fb5-3257-ca9fa7c604bc@cornell.edu> <60cf587b-5d83-31d6-f0af-56979b221425@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="12192"; mail-complaints-to="usenet@ciao.gmane.io" Cc: larsi@gnus.org, 56025@debbugs.gnu.org To: Ken Brown , Sean Whitton , Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Mon Jul 18 07:27:23 2022 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1oDJHt-0002yV-QJ for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 18 Jul 2022 07:27:21 +0200 Original-Received: from localhost ([::1]:42218 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oDJHs-0006kh-CH for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 18 Jul 2022 01:27:20 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:55676) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oDJHe-0006j4-Gx for bug-gnu-emacs@gnu.org; Mon, 18 Jul 2022 01:27:06 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:51247) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oDJHa-000797-SQ for bug-gnu-emacs@gnu.org; Mon, 18 Jul 2022 01:27:06 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1oDJHa-0007Ge-FP for bug-gnu-emacs@gnu.org; Mon, 18 Jul 2022 01:27:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Jim Porter Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 18 Jul 2022 05:27:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 56025 X-GNU-PR-Package: emacs Original-Received: via spool by 56025-submit@debbugs.gnu.org id=B56025.165812201327921 (code B ref 56025); Mon, 18 Jul 2022 05:27:02 +0000 Original-Received: (at 56025) by debbugs.gnu.org; 18 Jul 2022 05:26:53 +0000 Original-Received: from localhost ([127.0.0.1]:49006 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oDJHO-0007GD-Cc for submit@debbugs.gnu.org; Mon, 18 Jul 2022 01:26:53 -0400 Original-Received: from mail-pj1-f44.google.com ([209.85.216.44]:40525) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oDJHI-0007Fw-2I for 56025@debbugs.gnu.org; Mon, 18 Jul 2022 01:26:48 -0400 Original-Received: by mail-pj1-f44.google.com with SMTP id q13-20020a17090a304d00b001f1af9a18a2so3039000pjl.5 for <56025@debbugs.gnu.org>; Sun, 17 Jul 2022 22:26:44 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=subject:to:cc:references:from:message-id:date:mime-version :in-reply-to:content-language:content-transfer-encoding; bh=RcwPoyuKxBJV+NT/aspE0sqtAkMvCF6NgJqpheRqAbw=; b=UDcaAY8lUDblZ3hnMOwAauJkLb+W1uQ03GUOcrfYU4arNPb4F6TaW1HNoTiY4RckhS 0WMQ0UttLjPRct8oOnfCUEeMXoVd+Q3H1legTrtk2SQlnXD4qVCOae6n86mztoXBB6u9 qZ+bXs/15H1HARGVMfgSS4kwX2PPCR6WTcwwAqHYs3sd9sXxsDOR3HLMrF7OX9+kDQgY kh6H1Loc1i+f701rycyhzwcRaZQPJLrXfzHdNM1WF94BnPRh+O2cILvEbO9xOnXEU3MG Rn/uHaP1ZSsB5zf31vDaTr8m7I6sa0vahlNUoPge58BP1M/l1L0bxNgciAqyJAeNm9Kl GWmQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=RcwPoyuKxBJV+NT/aspE0sqtAkMvCF6NgJqpheRqAbw=; b=pQmeXZHQsRNcZba1KlgkHMKznMI/uYJ/jriZncNws6Q9IsaBSDfTBlpJVtYlezCBaI E8l/4cDt2Cb0oYNRzPspNrPjPKlH36lBsUrMoTdgHdl9NM0caCeZA3HoEr3CfQDcyCIk nIyQl04vck/cVnmWiWI8IXnO7RtVNUILhpJSbgJ0/nz1dE+rYhLowpERO6cv+NjyJ+5y tsoxNkE7WbKur7dgwqThFbrmHFiU8m+Z5i7ERZgHLvdl8ErX3z3X29P0PES9s16/pE7W Z2EuDgUMWTZC6g8uUTZTOjYqSf0XN0+VnuYuPgwR7cH+ZUWC8jho2pVzC52jtFFvnLrr a1Kw== X-Gm-Message-State: AJIora/RnYhJK+uVap4nnQJq/7FVYF9+mAyYTz1O+Z0CaL+fHeLCnTSl sF9RxBerfxISllCqZP00lueiLPomLRE= X-Google-Smtp-Source: AGRyM1tJF4inr1M+2pCqKcmVrF/j/4bfVL1F2aOxelXNafaC/KfWliOEcey1l21zHQzaaHx5RmJPHQ== X-Received: by 2002:a17:903:451:b0:16c:b873:4a8 with SMTP id iw17-20020a170903045100b0016cb87304a8mr19423896plb.47.1658121997098; Sun, 17 Jul 2022 22:26:37 -0700 (PDT) Original-Received: from [192.168.1.2] (cpe-76-168-148-233.socal.res.rr.com. [76.168.148.233]) by smtp.googlemail.com with ESMTPSA id e35-20020a630f23000000b0040c40b022fbsm7000503pgl.94.2022.07.17.22.26.35 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Sun, 17 Jul 2022 22:26:36 -0700 (PDT) In-Reply-To: Content-Language: en-US X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:237323 Archived-At: On 7/17/2022 2:59 PM, Ken Brown wrote: > On 7/16/2022 10:35 PM, Jim Porter wrote: >> Ok, attached is a WIP patch to do this. It seems to work for me under >> Cygwin, although I've only lightly tested it in that environment. If >> this works for you too, I'll finish cleaning this up and add >> tests/documentation for it. > > It does work for me too.  Thanks! Great! This should make Eshell behave a bit more similarly to other shells, so hopefully this will help prevent other issues in this area. >> Note that in my patch, I temporarily undid my previous patch to send >> EOF multiple times. This is just for testing purposes, but since we're >> using a pipe for this connection now, a single call to >> `process-send-eof' should be sufficient. > > There shouldn't be a need for any calls to process-send-eof.  This is a > noop anyway when writing to a pipe, as it should be. Looking at the implementation of `process-send-eof', I think it's (somewhat misleadingly) also responsible for closing the file descriptor when writing to a pipe, so I believe we'll need at least one call to that function. As you say though, it shouldn't be too hard for Eshell to check whether it's writing to a pipe and only try to call `process-send-eof' once in that case.