From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2.migadu.com ([2001:41d0:403:4876::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms13.migadu.com with LMTPS id 6PMHDc40b2aqDwAAe85BDQ:P1 (envelope-from ) for ; Sun, 16 Jun 2024 18:54:06 +0000 Received: from aspmx1.migadu.com ([2001:41d0:403:4876::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp2.migadu.com with LMTPS id 6PMHDc40b2aqDwAAe85BDQ (envelope-from ) for ; Sun, 16 Jun 2024 20:54:06 +0200 X-Envelope-To: larch@yhetil.org Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=excalamus.com header.s=zmail header.b=BRK+F0iF; 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=none; arc=pass ("zohomail.com:s=zohoarc:i=1") ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1718564046; 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: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post:dkim-signature; bh=Z7FGi5ThQyHIXCErGXgjHCNQaGHnGi7kWNpdk6BTtyg=; b=U5O9IIGRR/pt247f3wuChrfOxqG7SlBWEobQPNhJnadZ+82FYFQHLtz/GlH1Hb6wpf0iDu Ix48zyFhqiTUMCW3YzqkmrcYeYd9pvdkF64CKIEWS0uGgeZijUQohZqMsofG9WETa47oNp qYXGEr5H7oqamnhbX9Qq2vnZwBPPsa+vegpbmM1MHLD7Octhxa38oL3MlLqVHHsDHyEde7 IX/Y9aZTz7Xj2SZmGKSOvnEBU0r+IEwNMAQS3bmfNovMzgcqt9W8IldZugGw4RmUloPkXx osltMV2nvkTgy9J/5QAhVGBMwy+09M6grv1HR0orkQb08/qiw3Nk2H2MIdj/Ng== ARC-Authentication-Results: i=2; aspmx1.migadu.com; dkim=pass header.d=excalamus.com header.s=zmail header.b=BRK+F0iF; 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=none; arc=pass ("zohomail.com:s=zohoarc:i=1") ARC-Seal: i=2; s=key1; d=yhetil.org; t=1718564046; a=rsa-sha256; cv=pass; b=bxudGpRvbX/FlYcLKzrv0Tce+rl7fRbz9zI3I+a+a8PeD4GYmcBCjxrrxSRkx4nOuRg29e /YFclakihPZYcOUKo7IJ7pgQqokBcQYSRmSqURz+7LMIeVZYsDSfSFPE455hzwOderekOU pzg7oXceR5u+Rui3WJ0l+HJ2D3CI+di4FiMSuSBxbZvCyWLlCrVeeqAiVIytFB4EYG2LIn z/E5Ac9XERFywiwPBl8CLTevxYS1a+YofDyB1c0iaR8TLx3/0/dE6wYyo7jwEjU3fGF7JZ EJPZ2daMcTn/Nm3b+NoLlkgR49KijWA/960QL+QkEjkGyFFH60IF9zd650p+Kg== 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 EFF106BD4F for ; Sun, 16 Jun 2024 20:54:05 +0200 (CEST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1sIv01-0000it-RJ; Sun, 16 Jun 2024 14:53:09 -0400 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 1sIv00-0000il-Tv for emacs-orgmode@gnu.org; Sun, 16 Jun 2024 14:53:08 -0400 Received: from sender4-pp-f112.zoho.com ([136.143.188.112]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1sIuzz-0007BP-73 for emacs-orgmode@gnu.org; Sun, 16 Jun 2024 14:53:08 -0400 ARC-Seal: i=1; a=rsa-sha256; t=1718563983; cv=none; d=zohomail.com; s=zohoarc; b=mBFaDx701x9iXEJT75qPIdSVdDrg/hdX4h9p+omUiNp8KHNu69nZ4bR+zSagXxPAZMWmdQVrbZ1myjQ853bkcUkQxX6hJEinEn1989Uj+i9Kr9YDOPFOuREZ3IO0T7/50u3qLmx2tDqN4E/AyPJz65gprS1euElgLWQqoE5cuKA= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1718563983; h=Content-Type:Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:In-Reply-To:MIME-Version:Message-ID:References:Subject:Subject:To:To:Message-Id:Reply-To; bh=Z7FGi5ThQyHIXCErGXgjHCNQaGHnGi7kWNpdk6BTtyg=; b=SNR5C8LbTCIghbwBIvz/djSCZO8feH2ObUaaHhfDpAhciUqrlC8QQ6mbKJ3B1ghGiP843Y40VEYvkbaNfWIUeHkYllo3xhHayrV6y8Gi93hfuV39PTv7ocfcDJXWtnRHQJR9X9qV+Bc70ZfD0cFP/fJusVrvOd1WDU4eomgivj0= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass header.i=excalamus.com; spf=pass smtp.mailfrom=matt@excalamus.com; dmarc=pass header.from= DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; t=1718563983; s=zmail; d=excalamus.com; i=matt@excalamus.com; h=Date:Date:From:From:To:To:Cc:Cc:Message-ID:In-Reply-To:References:Subject:Subject:MIME-Version:Content-Type:Content-Transfer-Encoding:Message-Id:Reply-To; bh=Z7FGi5ThQyHIXCErGXgjHCNQaGHnGi7kWNpdk6BTtyg=; b=BRK+F0iFsD4Y/1MZdILH/L2bwcREUY36t3UAC1QP2PrJFZyhQOLmtroQWcsgjwvY fjaaczCju0E9v7GSwDQsKxAeVlqZigZ3gS3ow6wwsezhRa3ouwiTPppxXYtlFKzzm8N VJnJEPbAkC79KU9AMqFjtcjHk4VMbLxFVjx932yI= Received: from mail.zoho.com by mx.zohomail.com with SMTP id 1718563981105430.7735378884174; Sun, 16 Jun 2024 11:53:01 -0700 (PDT) Date: Sun, 16 Jun 2024 20:53:01 +0200 From: Matt To: "Suhail Singh" Cc: "Org mailing list" Message-ID: <1902265471c.11e1aa5961508019.932872149697165868@excalamus.com> In-Reply-To: <87cyop3445.fsf@gmail.com> References: <87cyop3445.fsf@gmail.com> Subject: Re: ob-shell: possibly missing initiate-session functions? MIME-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Importance: Medium User-Agent: Zoho Mail X-Mailer: Zoho Mail Received-SPF: pass client-ip=136.143.188.112; envelope-from=matt@excalamus.com; helo=sender4-pp-f112.zoho.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 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_NONE=-0.0001, RCVD_IN_MSPIKE_H4=-0.01, RCVD_IN_MSPIKE_WL=-0.01, 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-Country: US X-Migadu-Flow: FLOW_IN X-Spam-Score: -7.04 X-Migadu-Queue-Id: EFF106BD4F X-Migadu-Scanner: mx10.migadu.com X-Migadu-Spam-Score: -7.04 X-TUID: ulKFxPlvFNDh ---- On Mon, 10 Jun 2024 04:48:10 +0200 Suhail Singh wrote ---=20 > Currently (Org 9.7.3), org-babel-switch-to-session invokes > org-babel-initiate-session which tries to invoke > org-babel--initiate-session. On a related note, ob-shell defines > org-babel-sh-initiate-session (and uses it within > org-babel-execute:shell). >=20 > However, there are no definitions for org-babel-shell-initiate-session > nor org-babel-bash-initiate-session etc. This means that trying to use > org-metadown (which invokes org-babel-switch-to-session) on shell and > bash language session blocks results in the following errors > respectively: >=20 > #+begin_comment > org-babel-initiate-session: No org-babel-initiate-session function for= shell! > org-babel-initiate-session: No org-babel-initiate-session function for= bash! > #+end_comment >=20 > Is this a bug? If so, does org-babel-shell-initialize need to be > patched to set up function aliases pointing to > org-babel-sh-initiate-session ? >=20 > FWIW, I have been using such aliases in my personal config for bash and > shell language blocks and they seem to behave as expected. Thank you for your message! Yes, I would consider this a bug. I agree, defining an alias within "org-babel-shell-initialize" seems reason= able. However, it's important that "explicit-shell-file-name" is set to th= e appropriate shell name. In your case, I suspect it's a coincidence that = aliasing "org-babel-sh-initiate-session" works. A "shell" block defaults t= o "explicit-shell-file-name". This, I suspect, is "bash" in your case, yet= may be something different on another system. The alias would need to clo= se over "explicit-shell-file-name" like is done with "org-babel-execute:nam= e". -- Matt Trzcinski Emacs Org contributor (ob-shell) Learn more about Org mode at https://orgmode.org Support Org development at=C2=A0https://liberapay.com/org-mode