From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Aleksander Trofimowicz via "Bug reports for GNU Emacs, the Swiss army knife of text editors" Newsgroups: gmane.emacs.bugs Subject: bug#62093: [PATCH] Let processes read nothing from stdin in tramp Date: Fri, 17 Nov 2023 20:10:34 +0000 Message-ID: <87wmugdpsl.fsf@n90.eu> References: <87wmvaudbi.fsf@n90.eu> <87edh5s9e9.fsf@gmx.de> <877cmupx1c.fsf@n90.eu> <87y1f430al.fsf@gmx.de> Reply-To: Aleksander Trofimowicz Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="23740"; mail-complaints-to="usenet@ciao.gmane.io" Cc: Benjamin Orthen , 62093@debbugs.gnu.org To: Michael Albinus Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Fri Nov 17 22:38:22 2023 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 1r46Xd-0005w8-SY for geb-bug-gnu-emacs@m.gmane-mx.org; Fri, 17 Nov 2023 22:38:22 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1r46XM-00018Y-69; Fri, 17 Nov 2023 16:38:04 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1r46XJ-00011j-TN for bug-gnu-emacs@gnu.org; Fri, 17 Nov 2023 16:38:01 -0500 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1r46XJ-0006Z0-LG for bug-gnu-emacs@gnu.org; Fri, 17 Nov 2023 16:38:01 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1r46XJ-0005xC-Mm for bug-gnu-emacs@gnu.org; Fri, 17 Nov 2023 16:38:01 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Aleksander Trofimowicz Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 17 Nov 2023 21:38:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 62093 X-GNU-PR-Package: emacs Original-Received: via spool by 62093-submit@debbugs.gnu.org id=B62093.170025708022879 (code B ref 62093); Fri, 17 Nov 2023 21:38:01 +0000 Original-Received: (at 62093) by debbugs.gnu.org; 17 Nov 2023 21:38:00 +0000 Original-Received: from localhost ([127.0.0.1]:47256 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1r46XI-0005ww-CJ for submit@debbugs.gnu.org; Fri, 17 Nov 2023 16:38:00 -0500 Original-Received: from mx.n90.eu ([65.21.251.117]:55378) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1r46XF-0005wk-QK for 62093@debbugs.gnu.org; Fri, 17 Nov 2023 16:37:58 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=n90.eu; s=default; t=1700257075; bh=sOjhG5OtFxBKOGM97rJ27N4Abyq6zHZ/F6JNpqsqkrY=; h=References:From:To:Cc:Subject:Date:In-reply-to; b=ECJc0BkqrMAgrDRCrrQyfQRYISDjxo8UIRgAtCeGsVaX1Dnk7B1i3kNcxG/W/umlw RaU8XclO4vS7d1gMLd4tllpYgJ2UH7HQyzCSb1ThEg2MSNX9L/T3rgvps27IhyDH0t gUusYzPpvClaXyxu8BEJZwW5xy8sGFLHaNcAYEd03iC08hAMAwvjTpnRKCzqq+Hcl0 V/x2npP/24i1eNWuOuAL2HK/a+MbtUUjU7di65tp2b4BT+WphqQyFYdlKfuIZ47jYw WI2GS2la5sCEGq/dbClN2WTdow7vAOs1kavFsBwpwDLjEWqISAvet3cHXWqDUDq9cz Tg+t20YJvLmaQ== In-reply-to: <87y1f430al.fsf@gmx.de> X-Mailer: boring 1.0 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-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:274522 Archived-At: Hi Michael, Michael Albinus writes: > I cannot speak for the local case. But in Tramp, we need to set "stty > -icanon ..." for the pipe connection type in order avoid blocking > situations with larger hunks of data, see the comment there. And the use > case of magit-start-process would be better with the connection type > pty, at least when calling Tramp. > Re-configuring a TTY device via "-icanon" does not only lift the 4k input line limit; there are other far-reaching consequences. Most notably: a handful of the terminal special characters are delivered straight to stdin of a managed process, which more often than not is unprepared to handle such a situation (e.g. the VEOF character). I would argue in the Tramp context doubly so, since the connection-type is set to 'pipe' somewhere up in a stack. It also invalidates certain expectations most people have while invoking process-send-eof. These are reasons magit stopped working, and my patch was a half-baked attempt to address the problem by other means. Please drop it. At the same time I would encourage you to revert the change that introduced the noncanonical mode, since the current state is very confusing and breaks existing code. A dedicated defcustom should cater for those who deal with large input data. Ideally no pty should be allocated if one asks for 'pipe' (by employing ssh connection multiplexing?). -- Kind regards, at