From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2.migadu.com ([2001:41d0:403:58f0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms13.migadu.com with LMTPS id QF9gCjGXFmcC9wAAe85BDQ:P1 (envelope-from ) for ; Mon, 21 Oct 2024 18:02:41 +0000 Received: from aspmx1.migadu.com ([2001:41d0:403:58f0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp2.migadu.com with LMTPS id QF9gCjGXFmcC9wAAe85BDQ (envelope-from ) for ; Mon, 21 Oct 2024 20:02:25 +0200 X-Envelope-To: larch@yhetil.org Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=posteo.net header.s=2017 header.b=JbuOXuGL; 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=1729533744; 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=4lLe4b6302I1pEKO3YH+VmMjb+SAJlmcfGpiolOhM3Y=; b=KLBVxET/1N1EzbOVo9N66l3mdXE7qDt5mp9AiIZWR8nF5MS9+BwPrPw5CPDSx7FTIJ9GpV Z3HXcTb24Ox4s3gMfqATSjVxBOwfMViOqz837ZmiR8ZzzoeLXe/PcR0XiNPcmroecDNwdJ XOZrFs7OeAA8hXzqZ/5TlKhIJ5DhB32z1e/3eFHkQorbrnHa6aaarxL8YHqZVS3UG7lkoV FU88MlfVpU920IxRgRkTEOpR4RD/p3CXyHIgBAhNHahZ/ktvQ8FMMbib7331H0O+edhSpc rKRcprmHcSCEzt2mOP+7TSSyXkUl02SDhy7J6jigOT/vfeZ2OqsUeXy4zGLNRQ== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=posteo.net header.s=2017 header.b=JbuOXuGL; 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=1729533744; a=rsa-sha256; cv=none; b=MAk22g7Y1rOs9gpJHoPAR7WeA8/Fd9YIpS3CqL2YnD29rGjyTSXwspJd0MGPkJB+83r04Q 8+q58GzCkjOAZQBIrnvHzWb05tlle+TlfUPb4meT4WttyKq4Hc1/idNMFhtzukk4Xw5k49 8uIaudTS4qY5YsFFimV2HYBa60aM51ks46Y/2pCKjF/O32qkE804MZ/AC9zkkmj4eOdsCg Vu64N4F17B7hQhYEsAu8cb5rvwEaeeoW6kPEtNLuE/7gPv1cmC8lq0zNrNxl4AJUga6AKY 13of3/hrHIL1ST5+aTGZ71V9wdg1JxO9JauQ4Vgcbx0CVCejEI702/V5wP4NhQ== 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 72AE343BF0 for ; Mon, 21 Oct 2024 20:02:24 +0200 (CEST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1t2wim-0000m4-RU; Mon, 21 Oct 2024 14:01:37 -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 1t2wih-0000aa-By for emacs-orgmode@gnu.org; Mon, 21 Oct 2024 14:01:32 -0400 Received: from mout02.posteo.de ([185.67.36.66]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1t2wid-0007de-He for emacs-orgmode@gnu.org; Mon, 21 Oct 2024 14:01:30 -0400 Received: from submission (posteo.de [185.67.36.169]) by mout02.posteo.de (Postfix) with ESMTPS id 3F0CC240101 for ; Mon, 21 Oct 2024 20:01:15 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1729533675; bh=+9OmYFwU5wkxNWvvvaBunQXSrw8Euzfu+6f7dihAy4w=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version:Content-Type: From; b=JbuOXuGLvsr1Fb+VtmkuM5UJuHH/WvMDE9kf7TQU/t8SCq6v/RU+zXJf8bZfYVD2c dxwnOxsDhQIBn7qL96REzPYA6BkGNT6UT4LHVg854a7c0KwxVU72R6iaqONmLa1CZX 0BMSDJ8NQdETEOksI9c9BYK5md+9vXd1uma/sbbb2GmTj897/yBGOWKimNw00Q+rYM FTiJxiOVpPSK7mhSebwrR/ybnG6+PAz+nJP3hRgwT5S0B7lGG1rkGmGNYEiLBluvgW NF+Hm/bweQUxg/mUeyYzCatWUwDsyWubciX7GTdsT5hbjmXEpDkl9BISXkISrlH1M7 +ehQV1G+JNRhA== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4XXNQy1svqz9rxF; Mon, 21 Oct 2024 20:01:14 +0200 (CEST) From: Ihor Radchenko To: Jack Kamm Cc: "Dr. Arne Babenhauserheide" , Rudolf =?utf-8?Q?Adamko?= =?utf-8?Q?vi=C4=8D?= , emacs-orgmode@gnu.org Subject: Re: Org Babel says 1 + 1 in Python is None In-Reply-To: <874j563shr.fsf@gmail.com> References: <87y143x4q0.fsf@web.de> <87plo4z0vi.fsf@localhost> <87bjzf45g5.fsf@gmail.com> <8734krru39.fsf@localhost> <874j563shr.fsf@gmail.com> Date: Mon, 21 Oct 2024 18:03:00 +0000 Message-ID: <877ca19vvv.fsf@localhost> MIME-Version: 1.0 Content-Type: text/plain Received-SPF: pass client-ip=185.67.36.66; envelope-from=yantar92@posteo.net; helo=mout02.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_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, RCVD_IN_VALIDITY_CERTIFIED_BLOCKED=0.001, RCVD_IN_VALIDITY_RPBL_BLOCKED=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 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-Migadu-Scanner: mx11.migadu.com X-Migadu-Spam-Score: -1.15 X-Spam-Score: -1.15 X-Migadu-Queue-Id: 72AE343BF0 X-TUID: brKt5dr+1gkZ Jack Kamm writes: > Well, ob-python sessions implement this sort of parser in > `org-babel-python-format-session-value', which AFAIK is robust. Interesting. I did not remember this. > I think it would be feasible to switch non-session blocks to use this > parser, which IMO is nicer behavior -- the "return" statements always > felt weird to me. > > But a major reason not to do it is to avoid breaking compatibility. Lots > of old ob-python nonsession blocks with "return" statements out there. May we detect if there is a return statement? -- Ihor Radchenko // yantar92, Org mode contributor, Learn more about Org mode at . Support Org development at , or support my work at