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#65551: 29.1; Eshell on MS-Windows using plink: 'plink' is not recognized as an internal or external command... Date: Sat, 26 Aug 2023 12:16:12 -0700 Message-ID: <8e61bce9-e818-c52c-7478-7c11452735ec@gmail.com> References: <861qfpnb9y.fsf@gmx.com> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="18530"; mail-complaints-to="usenet@ciao.gmane.io" To: Jordan Wilson , 65551@debbugs.gnu.org, michael.albinus@gmx.de Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sat Aug 26 21:17:21 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 1qZymc-0004Vj-Nf for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 26 Aug 2023 21:17:18 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qZymR-0003uF-AC; Sat, 26 Aug 2023 15:17:07 -0400 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 1qZymH-0003rL-Dh for bug-gnu-emacs@gnu.org; Sat, 26 Aug 2023 15:16:57 -0400 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 1qZymH-0002KQ-5j for bug-gnu-emacs@gnu.org; Sat, 26 Aug 2023 15:16:57 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qZymM-000895-7g for bug-gnu-emacs@gnu.org; Sat, 26 Aug 2023 15:17: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: Sat, 26 Aug 2023 19:17:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 65551 X-GNU-PR-Package: emacs Original-Received: via spool by 65551-submit@debbugs.gnu.org id=B65551.169307738831262 (code B ref 65551); Sat, 26 Aug 2023 19:17:02 +0000 Original-Received: (at 65551) by debbugs.gnu.org; 26 Aug 2023 19:16:28 +0000 Original-Received: from localhost ([127.0.0.1]:43451 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qZylo-00088A-2v for submit@debbugs.gnu.org; Sat, 26 Aug 2023 15:16:28 -0400 Original-Received: from mail-pl1-x632.google.com ([2607:f8b0:4864:20::632]:42055) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qZylk-00087w-RE for 65551@debbugs.gnu.org; Sat, 26 Aug 2023 15:16:26 -0400 Original-Received: by mail-pl1-x632.google.com with SMTP id d9443c01a7336-1c0bae4da38so13627515ad.0 for <65551@debbugs.gnu.org>; Sat, 26 Aug 2023 12:16:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1693077373; x=1693682173; h=content-transfer-encoding:in-reply-to:from:references:to :content-language:subject:mime-version:date:message-id:from:to:cc :subject:date:message-id:reply-to; bh=EwfM2Nx5jh/z8ymY2Ygy+jWI5aYl+aJiCrO2gZFnWoM=; b=KDzQNxk1wu/+zpP/GyPDspLEKMJDs5b8rO4qbw3EQcOWwqCyw7UtSxAnFCrBt6x7IK SQcp2iHbz3ajQU6aI3gsGETL1XkWr7BmN6oWdAfzjRKMyrGMOMmM7rIZ5SnRn4QmtzVK W3/Gc89I/zLYufDi6Yb+K0TsJrpaDELRWKZrHrLWeIQdkwARAd7MXEnSCxT78xq5MgsG 3ynmj25yNgiQBtqiVWuSn9mNWwV9ZAES8iumE0hu1ExN4sjgOJ6T4teUemFejLnbUDpr qvy0zGyU9iUiPxSTi/IuGF9mwupb2YVvHXGKBGqk21la3DTNQtl4j4yuz+b5I++0moeF nwBQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1693077373; x=1693682173; h=content-transfer-encoding:in-reply-to:from:references:to :content-language:subject:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=EwfM2Nx5jh/z8ymY2Ygy+jWI5aYl+aJiCrO2gZFnWoM=; b=Tux9Qk9SaxBJ67QMXWEuycZxK3g4AdYSnaZ52VN6wbgWYFmvYV5A8E9XBBUERnPMIO 4FTvgUYc3M4vyqpCC9yQxjBGBN30yAqzBNjUSG+B4qtDcIXkxtmcnAg1rzh3y9aQP83J JYeHRwkLoCw6UajgdFOSaujw7JjX28vKyHx3BiINjrbskISbfr2wzjkzjycigltw6TGg OcI0stKlIFZLpkTUQziJmPIfUE9fvuSn2UcU7IcGtP5R+UWKZwkAqzqzeWrVDra1QVYh x9jtJ9TUty1CLJbeXKcLnIdQcgNuMCoEePbL2Pq/vunDmtZzV4oLG5wej3hlM100UgnL dp+A== X-Gm-Message-State: AOJu0YwQyJYmjeKsXHz2uBCsvI6xSKq/2hDBrhYcroYeFavOC/cGfRYW JOYZ05aXCb3/MsR8O9if2gc= X-Google-Smtp-Source: AGHT+IFc209WoDky+RqruIxRVR3QYjdnhnPHSoh14dzLu6KI4fPpuV5RQTYwvJT1YRz2DuVtxsU3AA== X-Received: by 2002:a17:902:e5c9:b0:1b7:ca9c:4f5c with SMTP id u9-20020a170902e5c900b001b7ca9c4f5cmr31814596plf.28.1693077373458; Sat, 26 Aug 2023 12:16:13 -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 b19-20020a170902ed1300b001bb99ea5d02sm4082727pld.4.2023.08.26.12.16.12 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Sat, 26 Aug 2023 12:16:13 -0700 (PDT) Content-Language: en-US In-Reply-To: <861qfpnb9y.fsf@gmx.com> 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:268516 Archived-At: On 8/26/2023 7:11 AM, Jordan Wilson wrote: > I've found a bug in Eshell on MS-Windows on 29.1. This is a regression > from 28.2. When connected to a remote machine using putty's "plink", > using any commands on the remote machine (e.g. not built-in to eshell) > prints this error in the eshell buffer (details replaced): Thanks for reporting this. I can reproduce this issue. Does evaluating the following work? (setf (alist-get 'tramp-login-program (alist-get "plink" tramp-methods nil nil #'equal)) (list (concat "\"" (executable-find "plink") "\""))) If so, I think I've identified the bug: in 'eshell-gather-process-output', we set the 'process-environment' to Eshell's environment variables. In a remote directory, this includes the remote PATH. However, that confuses Tramp, which uses that remote PATH to look for the local "plink.exe". Michael, what would be the best way to handle this? In Eshell, I want to be able to call 'make-process' to start a remote process using the local system's default 'process-environment', but for the remote process to see Eshell's modified environment variables. I see that there's 'tramp-remote-process-environment', but I'm not sure that's the right thing for me to use. Do you have any ideas?