From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2.migadu.com ([2001:41d0:303:e16b::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms8.migadu.com with LMTPS id MEv7Aa7FsmVkmwAAe85BDQ:P1 (envelope-from ) for ; Thu, 25 Jan 2024 21:33:50 +0100 Received: from aspmx1.migadu.com ([2001:41d0:303:e16b::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp2.migadu.com with LMTPS id MEv7Aa7FsmVkmwAAe85BDQ (envelope-from ) for ; Thu, 25 Jan 2024 21:33:50 +0100 X-Envelope-To: larch@yhetil.org Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=posteo.net header.s=2017 header.b=bNkn8Be1; spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org"; dmarc=pass (policy=none) header.from=posteo.net ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1706214830; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=4/K6fngLmWtlL0hEFa3MiQrgx85J2SWq1xHnUAOa8Ak=; b=EKii81/hChW/LoZbbEKvm6zCx0bMNsbeFiwk3pgaXHYXC93lhdcs+Pr4q6wAFK8OElnqi8 QaLqtBRm6CVgDHaTf19h7QJSSStdWCYCGqtM6ABxUAdMbMsbnk1eMZExwG/zYxpxZcv7uR bRguNj4KVtV4ePOiRfPkZKt7pFj4jaN0nyam4Bi/MsG/pqp0qiAUomDTbIWKIce8uU0jtv SxhZYlQvvQMVnJdOBUG2iKr8RYOIA7XPpgjyNiztIVs89216cydjedqLQtKCO255SA/81E +YMwv5fH6N/NhSa/uQyC3QFv/18oOnq99vhxjcVqOTbhrJzKv4RZkGVtJzWb3A== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=posteo.net header.s=2017 header.b=bNkn8Be1; spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org"; dmarc=pass (policy=none) header.from=posteo.net ARC-Seal: i=1; s=key1; d=yhetil.org; t=1706214830; a=rsa-sha256; cv=none; b=QXcuGczqilooR2uGM3whdUlPxMAy84GbzqNOdOxAxkCHfs/6pwFGMfU+jXNb6Fw8nqG/in co+6kmy1HqVZ9O4zdtQWqKlCzQBGQ1/hlHntuJNcsK0lCPnM7Pb0EFNeB+7+mQBM755R/C UPckDgzbtRxrTTYd3PQ1Yr2fX5RKpY9etr2WTu1VNYNVFP8UU1bF34IZUKqa7ocLUKWpAw xIdD9e6SZ0olR15/PAbK8aFoueL40/yHvBniO/jVH4VGijYGjR4yaICFinv3G7ekH3ihl/ bQcIgFNgLAs85t+NVv9RKJxbkyvy0e/2whZZNWbNDv5DUWwCzZn7ZmdfTRzoZg== Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 938D217148 for ; Thu, 25 Jan 2024 21:33:49 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rT6P3-00053O-Vm; Thu, 25 Jan 2024 15:32:50 -0500 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 1rT6P2-00053D-Kd for emacs-orgmode@gnu.org; Thu, 25 Jan 2024 15:32:48 -0500 Received: from mout01.posteo.de ([185.67.36.65]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rT6P0-0005U9-4D for emacs-orgmode@gnu.org; Thu, 25 Jan 2024 15:32:48 -0500 Received: from submission (posteo.de [185.67.36.169]) by mout01.posteo.de (Postfix) with ESMTPS id 40B7C240028 for ; Thu, 25 Jan 2024 21:32:43 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1706214763; bh=QXvu0gEc0dCq5Oa/LaTHXw9DF157JThOaBkNqPRMmEU=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version:Content-Type: From; b=bNkn8Be1Mg6Q62KXGnOvWl44OGALM1W8BvkMJbYK9rPYkMkAL2pDV29vpp+Yg1bVN ImTZd25z+imHC8Ysi7atLeJWCyKu33z+D+7/iHa0gYohQRuDR1apOXcKq5sE3vRRQX u6eXPhV7re8TOE3CDVxmuSp73NtfuYABk750UnxoVzccG/1FJmSDWFJSFraBCp4pTC KIV/ImEcRvLdstTRXi+tpmyCtj1V2qF6L5JnyAB5OLVIZpYTwFqTo6vsMgNyAMuQdv ZvJaOCNLN0o4e56oZ6hvIaRwFCtFK8RCf0eIiWWoaYYzJIgv85gwl9m7IjGCUndwpq wdkLhQF/GjLog== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4TLXZK2WNZz9rxD; Thu, 25 Jan 2024 21:32:41 +0100 (CET) From: Ihor Radchenko To: Matt Cc: Jack Kamm , emacs-orgmode Subject: Re: [BUG] conda doesn't work in ob-shell sessions In-Reply-To: <18d420bd33e.b270bb881931540.4087190415865625378@excalamus.com> References: <186283d230a.129f5feb61660123.3289004102603503414@excalamus.com> <87a61j3orj.fsf@gmail.com> <1864701b4b8.e37160d6373275.4308190093579612690@excalamus.com> <87357a2r27.fsf@gmail.com> <1864c676b9f.e1bae673679825.2955884247216895930@excalamus.com> <87ttzn1mai.fsf@gmail.com> <87h6jaj1pk.fsf@localhost> <87sf2q9ubd.fsf@gmail.com> <87o7de9gq5.fsf@gmail.com> <877ck1vass.fsf@localhost> <87le8ga8e3.fsf@gmail.com> <87v87ig3i0.fsf@localhost> <18d420bd33e.b270bb881931540.4087190415865625378@excalamus.com> Date: Thu, 25 Jan 2024 20:36:08 +0000 Message-ID: <87zfwtf8w7.fsf@localhost> MIME-Version: 1.0 Content-Type: text/plain Received-SPF: pass client-ip=185.67.36.65; envelope-from=yantar92@posteo.net; helo=mout01.posteo.de X-Spam_score_int: -43 X-Spam_score: -4.4 X-Spam_bar: ---- X-Spam_report: (-4.4 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_MED=-2.3, RCVD_IN_MSPIKE_H5=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-orgmode@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: emacs-orgmode-bounces+larch=yhetil.org@gnu.org X-Migadu-Flow: FLOW_IN X-Migadu-Country: US X-Migadu-Spam-Score: -9.88 X-Migadu-Scanner: mx13.migadu.com X-Spam-Score: -9.88 X-Migadu-Queue-Id: 938D217148 X-TUID: UyRtDAery5K9 Matt writes: > > What about the attached second version of the patch? > > I spent way too long trying to test it but I'm not sure I applied the patch correctly. > > I did the following, then realized that the patch I applied undid > changes (I assume) from a previous patch and so it must have been > applied on top of another one. I then wasted a bunch of time trying to > apply various combinations of the four patches I found in the thread. > One of the patches has trailing whitespace yet the various --ignore > options of git am didn't seem to ignore it. I guess I could have > looked at the timestamps and used git apply in sequence? The patch should apply cleanly on the latest main. No previous patches are needed. To simplify working with email patches, you may consider https://docs.kyleam.com/piem/Overview.html (Emacs package) It can apply patches right from inside Emacs email client. You can also use magit. > Should make autoloads also be run after applying the patches? Yes. Or make. Or you can use make repro to run clean Emacs using the current git branch. > Here's what I was able to do: > > In a VM, installed conda as described by their page. Specifically, my .bashrc was modified to activate the base environment. Closed terminal, opened it into the base environment, and created a new environment, emacs-test. > > Downloaded the latest org-mode by git-clone and did make autoloads. Added the org-mode git repo's lisp directory to my early-init.el. > > Applied patch with > > git apply --cache --ignore-space-changes --ignore-whitespace 2-v2-0001-lisp-ob-comint.el-Introduce-a-fallback-prompt-reg.patch > > Doing plain git apply failed. > > With the changes in the org-mode index, the base environment activated, I run 'emacs' and confirm I'm using the org-mode git with the patch applied (ob-shell doesn't set org-babel-comint-prompt in ). > > Then > > (org-babel-do-load-languages 'org-babel-load-languages '((shell . t))) > > #+begin_src shell :results output :session *shell* > conda activate emacs-test > #+end_src > > It hangs. C-g and switch to shell buffer shows the following (note, this was typed in and not copy-pasted because VM): Note that the patch should only make Emacs unhang after 5 seconds delay. I tested the patch with the following (conda does not available for my system): #+begin_src bash :results output :session *shell* PS1="prompt> " ls #+end_src -- Ihor Radchenko // yantar92, Org mode contributor, Learn more about Org mode at . Support Org development at , or support my work at