From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp12.migadu.com ([2001:41d0:403:4789::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms9.migadu.com with LMTPS id CF1sBosC42Q9SQEASxT56A (envelope-from ) for ; Mon, 21 Aug 2023 08:22:03 +0200 Received: from aspmx1.migadu.com ([2001:41d0:403:4789::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp12.migadu.com with LMTPS id WNs5BosC42T6TgEAauVa8A (envelope-from ) for ; Mon, 21 Aug 2023 08:22:03 +0200 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 599A6415C3 for ; Mon, 21 Aug 2023 08:22:02 +0200 (CEST) Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20221208 header.b=rb60EdG3; 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=gmail.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1692598922; 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=72Dlu6r2zEN2a5Kx5QoJi8y7TYrpRsT8CBLfkbaUQKs=; b=YTgnDrBGcbzUpnoYtkGdmK5o39UN1QgD3cO7nJ2sV04mrxw2i15TRVxpV193jy0yGed8p8 sj/Jt8yaOXJcZ0ZPGcoqLQZeGAgZwe/qzNSJSEhTjffSTjnwBAM6BHCIJOpauw6f6Xh6Xl EONJYIoIIJ4LdTzNsyVynwEj9OyfiZtGBXQgQ2mrR1MKxyt/pq8AYp7dyR8oT7aWPjlkYK sDIPk5AnczRCOt+fYEP+jlsNDigseAj3/a36FpdV4ZmW/wV0EhIWphs+QoRZ0HLW3GvSvQ /zOVU6UTb0sQpnLd4eZzo9Ozh/k4dXI0QTp1iTPhqy0W152WU6AUGbD+gI8Ebg== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1692598923; a=rsa-sha256; cv=none; b=jgTK6MiCJuKd30UTtyh09/jrucp4/uNe3jITYEIfFntkbnZXO+O4KspSoKgYZ3DHX2u+f4 XUUeuzfz/CpWzRUtbAEFuz33KQkaVF6syS/8WVCuC1Ax/bMG5ceDtP5uFgHALiwa0X5wRm +qltT75GiQ2EL8SgJiGOMKwsrhuzxXm679qL2IX9eblDqUQ+TORKZfmTmLevQs78FP0en0 s7Ol5grxQ33J+mQhcsSvQnonmXFX+Wz16mLXUoU62qo35L0LJxxQK+R2sm/OsL/DYlQwxP brZxQjncv99PFLNkle97zoIIgMyCyNfefkRsbwlG8lXthSzQuUQCBf14F/zSsQ== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20221208 header.b=rb60EdG3; 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=gmail.com Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qXyI6-000407-1w; Mon, 21 Aug 2023 02:21:30 -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 1qXyI3-0003zq-R7 for emacs-orgmode@gnu.org; Mon, 21 Aug 2023 02:21:27 -0400 Received: from mail-vs1-xe33.google.com ([2607:f8b0:4864:20::e33]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1qXyI1-000706-I7 for emacs-orgmode@gnu.org; Mon, 21 Aug 2023 02:21:27 -0400 Received: by mail-vs1-xe33.google.com with SMTP id ada2fe7eead31-44bf6f6eb3fso865716137.1 for ; Sun, 20 Aug 2023 23:21:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1692598884; x=1693203684; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=72Dlu6r2zEN2a5Kx5QoJi8y7TYrpRsT8CBLfkbaUQKs=; b=rb60EdG3O9pmMoFUx+YtdJfgikhz1H+9LCoiwDgKqn6y9LwTjLr1okIgLgygsDEhmc G4zBq5rzM11t/XIQf24hwIEPCaI3ccNWD6bLmIkdNH+MFxXs1zT0LEGtVjDor8XykCwT uKBXBw3m5Tvvj+Pd7KFyCFsLvCkgRvUGaAEj6TLKAwOxLptP1gV3bOSj5oYitIPwCR1X 7sDOCeThsdMNJcCsXIYStV9nIFsBYvYfW1VXMLkLI2I0KZaNjXeRJLqXp48E7hxuVSXb Pa3oGJZHiUa97c+ny249phOjpfM7D8IuU8/88zvqQgT+ELkAE4Ni//+mAOEcUubCh4Uw 9M6A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1692598884; x=1693203684; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=72Dlu6r2zEN2a5Kx5QoJi8y7TYrpRsT8CBLfkbaUQKs=; b=gOijI8p8o4XvmugAX9SuD81vJfhfSOaccvoFRagZmuFmggsl5/Ie/PhcOdaDXfQde+ 9HGtb4OyPYM8sE22ZySO7I87DRhbOBsduZv8HlCMLMVsHZzLt9SS2gTIOOeZt0ukpRCi YAXFFXiKnJvAHvTnhnHVV1gkVH8q9HLyJFUTXtbHZSHqN3f/Yn847y85fDt2ZrEvgm+w VlszO3SlDPottWt8hMJyFlHj4ITvs1jRz6VHIgRgJI1UVNX3Wl3kfcRDSB1aoBecMdY1 GKvWdrkXwZcz++XMP4gGI2yrAxpv2+APAjTwMTBW294WTx98PouA2EJ5M53BBfU3PTBD S81g== X-Gm-Message-State: AOJu0YzxTaf8wTgtMVm9G4qe59/TN5gQuzHAUOoL2gTNwra5RKlkYfuV JlhIMpuJ1bwazBXSo6OmOpTtMaa7ikj36Tqqh10= X-Google-Smtp-Source: AGHT+IFkDqJSdl5mhl5PL0NizXLoh2uFaQSbe9p3IuNSv4tRffZiHD8sqqKzV2J8hFI0SfZf/gPcFLq07NG88LUi/5M= X-Received: by 2002:a67:efc2:0:b0:44d:4a41:893a with SMTP id s2-20020a67efc2000000b0044d4a41893amr1885219vsp.7.1692598884274; Sun, 20 Aug 2023 23:21:24 -0700 (PDT) MIME-Version: 1.0 References: <87a5ur6f7w.fsf@gmail.com> <87edk0aqy5.fsf@gmail.com> <87ttsta7lw.fsf@gmail.com> In-Reply-To: <87ttsta7lw.fsf@gmail.com> From: Liu Hui Date: Mon, 21 Aug 2023 14:21:13 +0800 Message-ID: Subject: Re: [PATCH] ob-python results handling for dicts, dataframes, arrays, and plots To: Jack Kamm Cc: emacs-orgmode@gnu.org, Ihor Radchenko Content-Type: text/plain; charset="UTF-8" Received-SPF: pass client-ip=2607:f8b0:4864:20::e33; envelope-from=liuhui1610@gmail.com; helo=mail-vs1-xe33.google.com X-Spam_score_int: -17 X-Spam_score: -1.8 X-Spam_bar: - X-Spam_report: (-1.8 / 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_ENVFROM_END_DIGIT=0.25, 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.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: -7.24 X-Spam-Score: -7.24 X-Migadu-Queue-Id: 599A6415C3 X-Migadu-Scanner: mx1.migadu.com X-TUID: C7MYEjU95uyj > Thanks for reporting these misbehaving examples. I think the root of the > problem is `org-babel-script-escape', which is too aggressive in > recursively converting strings to lists. We may need to rewrite our own > implementation for ob-python. > > Also, I agree that moving the python code to an external file will be > helpful in handling these more complex cases. > > I may leave these tasks for future patches. In the meantime, we may have > to recommend ":results verbatim" for these more complex cases that > ":results table" doesn't fully handle yet. Understand. Thanks again for your work!