bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#49822: master e32c7d2: Change Python eval to send directly instead o


From: Augusto Stoffel
Subject: bug#49822: master e32c7d2: Change Python eval to send directly instead of using temporary files
Date: Wed, 08 Sep 2021 07:09:20 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux)

On Wed,  8 Sep 2021 at 03:17, "Barton, Mark" <Mark.Barton@disney.com> wrote:

> I tested the patch, 
> 0001-Reduce-limit-of-line-length-sent-to-the-Python-infer.patch, on
> macOS 11.5.1 and although my minimal example runs, my original document using 
> org babel
> session with multiple python blocks is failing with the message in the mini 
> buffer “Inline error:
> multiline result cannot be used”. I can try some lower value than 1024 and 
> report back, but
> below is what I saw with attempting to use the debugger to see what the 
> string looks like in my
> use case.

This looks like a different matter, and the patch below might solve it.
But I think it would make sense to open a new bug for this point, to we
get a chance of getting through with the TTY line limit discussion in
this thread.

diff --git a/lisp/org/ob-python.el b/lisp/org/ob-python.el
index 7911205d08..e3714964b7 100644
--- a/lisp/org/ob-python.el
+++ b/lisp/org/ob-python.el
@@ -352,7 +352,7 @@ org-babel-python--send-string
                   org-babel-python-eoe-indicator
                   string-buffer))
        (accept-process-output (get-buffer-process (current-buffer))))
-      (org-babel-chomp (substring string-buffer 0 (match-beginning 0))))))
+      (org-babel-chomp (substring string-buffer 1 (match-beginning 0))))))
 
 (defun org-babel-python-evaluate-session
     (session body &optional result-type result-params)





reply via email to

[Prev in Thread] Current Thread [Next in Thread]