From mboxrd@z Thu Jan  1 00:00:00 1970
Return-Path: <emacs-orgmode-bounces+larch=yhetil.org@gnu.org>
Received: from mp1 ([2001:41d0:8:6d80::])
	(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits))
	by ms0.migadu.com with LMTPS
	id cBWIGgTpo2CkegAAgWs5BA
	(envelope-from <emacs-orgmode-bounces+larch=yhetil.org@gnu.org>)
	for <larch@yhetil.org>; Tue, 18 May 2021 18:19:16 +0200
Received: from aspmx1.migadu.com ([2001:41d0:8:6d80::])
	(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits))
	by mp1 with LMTPS
	id mGExFgTpo2A2GwAAbx9fmQ
	(envelope-from <emacs-orgmode-bounces+larch=yhetil.org@gnu.org>)
	for <larch@yhetil.org>; Tue, 18 May 2021 16:19:16 +0000
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 D4A381AC02
	for <larch@yhetil.org>; Tue, 18 May 2021 18:19:15 +0200 (CEST)
Received: from localhost ([::1]:35456 helo=lists1p.gnu.org)
	by lists.gnu.org with esmtp (Exim 4.90_1)
	(envelope-from <emacs-orgmode-bounces+larch=yhetil.org@gnu.org>)
	id 1lj2R9-0006Cy-1G
	for larch@yhetil.org; Tue, 18 May 2021 12:19:15 -0400
Received: from eggs.gnu.org ([2001:470:142:3::10]:50022)
 by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <jackkamm@gmail.com>)
 id 1lj2QB-00068g-TQ
 for emacs-orgmode@gnu.org; Tue, 18 May 2021 12:18:15 -0400
Received: from mail-pj1-x102f.google.com ([2607:f8b0:4864:20::102f]:39624)
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128)
 (Exim 4.90_1) (envelope-from <jackkamm@gmail.com>)
 id 1lj2QA-00080h-3T
 for emacs-orgmode@gnu.org; Tue, 18 May 2021 12:18:15 -0400
Received: by mail-pj1-x102f.google.com with SMTP id
 o17-20020a17090a9f91b029015cef5b3c50so1823687pjp.4
 for <emacs-orgmode@gnu.org>; Tue, 18 May 2021 09:18:13 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
 h=from:to:cc:subject:in-reply-to:references:date:message-id
 :mime-version; bh=bOm1K/f5JtUDwpkJjxJsa4deZAixTUEDTqVWsSFTPdQ=;
 b=fbnVd6ghk7TDKYjp3Zg/88q70eIJg68rYcxXkpaBFa9nyZhNKCDAi7P8jzWyRsAfMC
 YW53d4zIy/1a63iyz5dbPfMOBx0WR2yW94spltfq5R43l82U19B1FA/tLqstODge8t/4
 xeqXs/BZeKAlwWM4rzMrV+Q0YVDAmqfW797uCEwkEqDPhhugZI2IpJ+WPw0Lpc+uBCj1
 bb/OUMPuOMOVukRuc+ZsSla3Bfl42bNEECSzpZ2dgWb+Riv0a5DNwUNRWXCaWdpPvuUQ
 MFl5y7ucWygRRm8KZBUcc4PcsD97EDQ9JHySIoD46U2anHdxHa25RHJ0mIUJnsdDUdmX
 JxpQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20161025;
 h=x-gm-message-state:from:to:cc:subject:in-reply-to:references:date
 :message-id:mime-version;
 bh=bOm1K/f5JtUDwpkJjxJsa4deZAixTUEDTqVWsSFTPdQ=;
 b=X8aTZKIZb0jpeMxo9s9Lxqgq63KnD/WiMmjlrVXO+VGBMdaerImmbYstWo73Pqswj3
 SVPtCUKB55nciHnN7TWGn29+rYuDYX0JLPShCJ7PfKZlViFOhDjy+fo1pH3v3xipW1aj
 z6x0sPSP3tHAt7Nqjb9giyfk9uyDInARuFvy/Qbim+qH9LOSlzUCfAUUItcZXr80mcvG
 1EOnLMpIBM7F6vtlIHfSxEFf5ZAQPe0PO+s6xl9O4Q2ELs8ZqnR/9gG2Tn4pe6De/q/3
 5Z2ovN28uXSrSh7Vx8Cj4eietbzwP/NxQQ1ZMFJxZiUVauff2Um9AXIO7+YE/aXRwdNs
 SksQ==
X-Gm-Message-State: AOAM530oJ+6iytvdntaqu0nkqde0oKBcSLnBPl1eu19RL8w8CzX91TlH
 ni9yuX1ew+dHNPDN52AlMVU=
X-Google-Smtp-Source: ABdhPJwbiE1uV2+yQsxB/AAQ3iHWJ6GgHQsQuIcBj4a5Db+CV101yk5/Z6nV0oUl6jMjF089LWyAyA==
X-Received: by 2002:a17:902:7e4e:b029:f0:d949:8ab3 with SMTP id
 a14-20020a1709027e4eb02900f0d9498ab3mr5487584pln.40.1621354692484; 
 Tue, 18 May 2021 09:18:12 -0700 (PDT)
Received: from localhost ([198.27.182.161])
 by smtp.gmail.com with ESMTPSA id j16sm4055905pfi.92.2021.05.18.09.18.11
 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);
 Tue, 18 May 2021 09:18:12 -0700 (PDT)
From: Jack Kamm <jackkamm@gmail.com>
To: ian martins <ianxm@jhu.edu>
Subject: Re: [PATCH] Async session eval (2nd attempt)
In-Reply-To: <CAC=rjb470RkVTR7yLWbqrttNGCYL_Vn-+wSCGrANqnWE8Roe=w@mail.gmail.com>
References: <87h7qi2l2m.fsf@gmail.com> <87lfdatkys.fsf@gmail.com>
 <871rczg7bi.fsf@gmail.com> <87h7lrcxhg.fsf@kyleam.com>
 <877dkqx4kn.fsf@gmail.com> <874kfudesx.fsf@gmail.com>
 <CAC=rjb470RkVTR7yLWbqrttNGCYL_Vn-+wSCGrANqnWE8Roe=w@mail.gmail.com>
X-Woof-Bug: Async session inline eval inserts result in wrong location
Date: Tue, 18 May 2021 09:18:11 -0700
Message-ID: <87y2ccyq0s.fsf@gmail.com>
MIME-Version: 1.0
Content-Type: text/plain
Received-SPF: pass client-ip=2607:f8b0:4864:20::102f;
 envelope-from=jackkamm@gmail.com; helo=mail-pj1-x102f.google.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, FREEMAIL_FROM=0.001,
 RCVD_IN_DNSWL_NONE=-0.0001, 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.23
Precedence: list
List-Id: "General discussions about Org-mode." <emacs-orgmode.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/emacs-orgmode>,
 <mailto:emacs-orgmode-request@gnu.org?subject=unsubscribe>
List-Archive: <https://lists.gnu.org/archive/html/emacs-orgmode>
List-Post: <mailto:emacs-orgmode@gnu.org>
List-Help: <mailto:emacs-orgmode-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/emacs-orgmode>,
 <mailto:emacs-orgmode-request@gnu.org?subject=subscribe>
Cc: Kyle Meyer <kyle@kyleam.com>, Org-Mode mailing list <emacs-orgmode@gnu.org>,
 Timothy <tecosaur@gmail.com>
Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org
Sender: "Emacs-orgmode" <emacs-orgmode-bounces+larch=yhetil.org@gnu.org>
X-Migadu-Flow: FLOW_IN
ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org;
	s=key1; t=1621354755;
	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=bOm1K/f5JtUDwpkJjxJsa4deZAixTUEDTqVWsSFTPdQ=;
	b=pNPu5cJRyW8TjCl96BqVUbXY36XWG2UmpM6Pvj8elrnaQc7UcXOfKtJtF4OysoXFfXQBQW
	33MC9Hqp4oeTlZ+7b3lbTn2a94jEXI3K1GDw2yWwKyOBVX6KhgEh/VQ4GO3gqjKyrWE8XA
	bVsYDwBEhpOlNHRGbMlhsj/V7maApT26Q0ZX1tb/mJzMnEEG008d0q2cmLO1aB3ZvgMKkd
	9O5auISdGJsbJydQia1kL6pc41duE4Ymi4fslBwyoTJQw1M4O5LSau+WzsalacuB8DW3DX
	klltPcJfeiY8DAyuu1fhfhOYGj1CRnzNSXKD6EmKHkpiJDpAreDD5IgBiSA9UQ==
ARC-Seal: i=1; s=key1; d=yhetil.org; t=1621354755; a=rsa-sha256; cv=none;
	b=riwKcIWH2qbBV4nYJXsl5w2GSTvxDmwJvlWgTfbJkUYhyoKquWJ1gB/Dm87tFl1OPLx+HK
	UgHloIz7XdvhaA30A76gsiozl6ZlzEWIiJ93ORitnT3zTYwhdnStHfmkXfyXXiOdjoujjU
	4GzkMz6aXRTrhohvuNOmggY9oQJs6i+BPoJ/TPaReNZpA2dpe4UGtFM/vHc6Yjueo4SSqj
	mldwpAr+zXi+W76r/xmTiY4w81rHxnjMbr7b0Tvunupeny5PKQGWhZqVOO4t+6GBvAmREh
	3z3Og05L22S+JEPPf06rPiiS73vKaBZRh0jG+uiHqvTT1ljqNYE2pMavVbPasQ==
ARC-Authentication-Results: i=1;
	aspmx1.migadu.com;
	dkim=fail ("headers rsa verify failed") header.d=gmail.com header.s=20161025 header.b=fbnVd6gh;
	spf=pass (aspmx1.migadu.com: domain of emacs-orgmode-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=emacs-orgmode-bounces@gnu.org
X-Migadu-Spam-Score: -1.34
Authentication-Results: aspmx1.migadu.com;
	dkim=fail ("headers rsa verify failed") header.d=gmail.com header.s=20161025 header.b=fbnVd6gh;
	dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none);
	spf=pass (aspmx1.migadu.com: domain of emacs-orgmode-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=emacs-orgmode-bounces@gnu.org
X-Migadu-Queue-Id: D4A381AC02
X-Spam-Score: -1.34
X-Migadu-Scanner: scn0.migadu.com
X-TUID: bfvqNQDd3DT0

Hi ian,

ian martins <ianxm@jhu.edu> writes:

> I gave this a try and it works for me. One thing I noticed is that if you
> run a call asynchronously, the final result ends up under the source block
> instead of the call.  In the example below both RESULTS were written after
> I ran the call.
>
>     #+name: test-call
>     #+begin_src python :results output
>       import time
>       time.sleep(5)
>       print("done")
>     #+end_src
>
>     #+RESULTS: test-call
>     : done
>
>     #+call: test-call() :session :async
>
>     #+RESULTS:
>     : 70e844920752b3411170716dc450c50f

Thank you for reporting. I'm adding the X-Woof-Bug header to this thread
so we can track it in updates.orgmode.org.