From mboxrd@z Thu Jan 1 00:00:00 1970 From: Myles English Subject: Re: wrong python version when using :session Date: Mon, 05 Sep 2011 23:26:46 +0100 Message-ID: <87d3fewrq1.fsf@bill.home> References: <87liu2x5jr.fsf@bill.home> <87vct6q4d2.fsf@gmail.com> Reply-To: emacs-orgmode@gnu.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Received: from eggs.gnu.org ([140.186.70.92]:58624) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1R0hc3-0006L5-LN for emacs-orgmode@gnu.org; Mon, 05 Sep 2011 18:25:56 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1R0hc2-0003KL-ED for emacs-orgmode@gnu.org; Mon, 05 Sep 2011 18:25:55 -0400 Received: from mail-ww0-f49.google.com ([74.125.82.49]:33849) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1R0hc2-0003KC-9E for emacs-orgmode@gnu.org; Mon, 05 Sep 2011 18:25:54 -0400 Received: by wwf10 with SMTP id 10so4471320wwf.30 for ; Mon, 05 Sep 2011 15:25:53 -0700 (PDT) In-Reply-To: <87vct6q4d2.fsf@gmail.com> (Eric Schulte's message of "Mon, 05 Sep 2011 11:35:37 -0600") List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode@gnu.org Eric, >> On Mon, 05 Sep 2011 11:35:37 -0600, Eric Schulte said: > Hi Myles, The `org-babel-python-command' variable is used to decide > which python executable is used to run non-interactive python code. > Session evaluation is performed using the interactive python mode > defined in the `org-babel-python-mode' variable. The distinction had not occurred to me and of course it should have. > From there the selected interactive python back-end is responsible > for all python interaction and you would want to look at the > relevant documentation for that tool to find out how to specify > which flavor of python is used. So for python-mode, the value of py-python-command decides the python version: (setq org-babel-python-command "python2" org-babel-python-mode 'python-mode py-python-command "python2" ) > Hope this helps -- Eric It did, thank you very much. Myles