From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2.migadu.com ([2001:41d0:303:e224::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms8.migadu.com with LMTPS id 0CmrKNmGu2VzugAAe85BDQ:P1 (envelope-from ) for ; Thu, 01 Feb 2024 12:56:09 +0100 Received: from aspmx1.migadu.com ([2001:41d0:303:e224::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp2.migadu.com with LMTPS id 0CmrKNmGu2VzugAAe85BDQ (envelope-from ) for ; Thu, 01 Feb 2024 12:56:09 +0100 X-Envelope-To: larch@yhetil.org Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=posteo.net header.s=2017 header.b=EVXT36ij; dmarc=pass (policy=none) header.from=posteo.net; 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" ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1706788569; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=402mZQdatj58zrELI998Mrp635y8p6Cg84z/jy9ab+I=; b=rg5DQSkVtocDtOtyght4bS/cHn94hqah12BXd9PplKkwmlLdHaAOs3+k6VWK9wXk+vAT0N v0lwL3pGs32/vQLXtHwVNLUgkQj+/TUsB+z1RC1RWG/9UE11wBhhVbPIZyfWigWs/YNf5o YA9MDL8lRG9ryfKrx1rrx0+1ikxD2BYtdkO3lL3npo4KfIfLW1to9vS+VuZfO5ue0W6n+P PdIKC/rlX8apwMjP1RIqBPoArK5h6RmWhCapG4Fd2BmJDOSiCFXgw7CF68CuZvxw0l4CK5 pFipAE4c/zO3YFQOCEYSWujo/FtQDmecn75IlHtvQfr7A+oO4t64iiHFSd/vcQ== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=posteo.net header.s=2017 header.b=EVXT36ij; dmarc=pass (policy=none) header.from=posteo.net; 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" ARC-Seal: i=1; s=key1; d=yhetil.org; t=1706788569; a=rsa-sha256; cv=none; b=ALiXQ6Sq0lkFoAbq5GWrPPsxEibx3Gru5/j5b/iehFv74975Due+laFSZBgcTpT0PCze1B ZydQUpQ/1LcIyBzn9HQWf27pAPlNa/JkPQCRSnewBTyM0+RcE8sZPapC9Jsx2vY8ZDQ73F Y6+PZyC49govcEF+6i12RWTpKcCsvkvGx3u8oN12mWSNRZX8JOb9iJtEbvJkvXzfemfs3C BJCUYmhE7JHDHuy1fESEjYJjyIezyJzIo4C2cYo7Q3pYB7JbAJSNr9guTgsjm4XcnQn76x W6bCoDu9Lvs2APK1C/L+raFeTE334MAuTB7t7X5ZTDpDqhdLS8cKed5sqqK0bg== 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 8A324666AD for ; Thu, 1 Feb 2024 12:56:09 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rVVf4-0002GT-Dr; Thu, 01 Feb 2024 06:55:19 -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 1rVVew-0002G2-4k for emacs-orgmode@gnu.org; Thu, 01 Feb 2024 06:55:11 -0500 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 1rVVeq-000389-2g for emacs-orgmode@gnu.org; Thu, 01 Feb 2024 06:55:09 -0500 Received: from submission (posteo.de [185.67.36.169]) by mout02.posteo.de (Postfix) with ESMTPS id A49FE240101 for ; Thu, 1 Feb 2024 12:55:01 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1706788501; bh=0V4nN+UVcxoegePr+7oxf35dGAcR+skQzO7I+3Kg6O4=; h=From:To:Subject:Date:Message-ID:MIME-Version:Content-Type:From; b=EVXT36ijslbfGoKjNKNKnU8xnS96GGoLvXtUzDQpn89xZUkvLJy8B3VtVPlgiToch QAO3t5NW9c/VcozicXoxLrj4NmRJxr//LLw9tfKSGKtXqVrZrq3hNwXkxgcGknyYXx EDy2QCtxKm9HIrLJvVn8eJeN6bJruibXf5typyzqAeZ4cqNrI5q54seChvEmsvt1dT br3e3JlSLoshlMEYwlAB0Z7FjVdlXlaZgJIbMYp0R9EOwPwz+lPxQQgMZFmBn3hTGn Vk2onZTCNuH+JZk/5pe6kSwbM0pc+Ui9oW3v/7p5P+fI4eTJoP8ILM4QsYNW1momHF 8aGA1gu4+ZnkA== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4TQclm6gFwz6txs; Thu, 1 Feb 2024 12:55:00 +0100 (CET) From: Ihor Radchenko To: emacs-orgmode@gnu.org, Jack Kamm Subject: [BUG] Unexpected result when evaluating python src block asynchronously [9.7-pre (release_9.6.17-1131-gc9ed03.dirty @ /home/yantar92/.emacs.d/straight/build/org/)] Date: Thu, 01 Feb 2024 11:58:31 +0000 Message-ID: <87o7d0mm54.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, 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.89 X-Spam-Score: -9.89 X-Migadu-Queue-Id: 8A324666AD X-Migadu-Scanner: mx12.migadu.com X-TUID: Lv60apY5bD3T This is a followup for another bug report https://orgmode.org/list/87plxg95u4.fsf@gmail.com Using the MWE from that report I am seeing a different bug and it is not very clear for me what is causing it. 1. When I create /tmp/bug.org with the following contents: #+begin_src python :dir otherdir :async yes :session pysession :return figname :results file value :mkdirp yes import matplotlib.pyplot as plt plt.figure(figsize=(1, 1)) plt.plot([1, 2]) figname = 'fig.svg' plt.savefig(figname) #+end_src 2. Go to Org git folder 3. make repro REPRO_ARGS="-l ob-python /tmp/bug.org" 4. Evaluate the code block 5. I get #+RESULTS: [[file:babel-GJy87v/python-xr8wq9]] rather than expected [[file:otherdir/fig.svg]] I use matplotlib 3.8.2-r1. The contents of Python REPL is suspicious: Python 3.11.7 (main, Jan 8 2024, 18:11:18) [GCC 13.2.1 20231216] on linux Type "help", "copyright", "credits" or "license" for more information. >>> ob_comint_async_python_file_/tmp/babel-s8nwvB/python-NmMFRv >>> This is most likely something about my current system setup - I can reproduce with other Org mode and Emacs versions. But I have no clue what is the cause. Emacs : GNU Emacs 30.0.50 (build 4, x86_64-pc-linux-gnu, GTK+ Version 3.24.39, cairo version 1.18.0) of 2024-01-30 Package: Org mode version 9.7-pre (release_9.6.17-1131-gc9ed03.dirty @ /home/yantar92/.emacs.d/straight/build/org/) -- Ihor Radchenko // yantar92, Org mode contributor, Learn more about Org mode at . Support Org development at , or support my work at