all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* save-excursion not working for python-shell-send-buffer
@ 2023-02-15  5:56 Chen Zhaoyang
  2023-02-15 13:24 ` Eli Zaretskii
  0 siblings, 1 reply; 4+ messages in thread
From: Chen Zhaoyang @ 2023-02-15  5:56 UTC (permalink / raw)
  To: help-gnu-emacs

Hello,

After executing (python-shell-send-buffer) my point does not return to
the mark but the beginning of the buffer. I am able to reproduce this
behavior on "emacs -Q" (my emacs is "GNU Emacs 30.0.50 (build 11,
x86_64-pc-linux-gnu, GTK+ Version 3.24.24, cairo version 1.16.0) of
2023-02-14"). I wrote a wrapper function like this

(defun site/python-shell-send-buffer ()
  (interactive)
  (save-excursion
    (python-shell-send-buffer nil)))

which works as desired (??).

Best,
Chen Zhaoyang




^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: save-excursion not working for python-shell-send-buffer
  2023-02-15  5:56 save-excursion not working for python-shell-send-buffer Chen Zhaoyang
@ 2023-02-15 13:24 ` Eli Zaretskii
  2023-02-15 14:23   ` Gregory Heytings
  2023-02-15 16:16   ` Chen Zhaoyang
  0 siblings, 2 replies; 4+ messages in thread
From: Eli Zaretskii @ 2023-02-15 13:24 UTC (permalink / raw)
  To: help-gnu-emacs

> From: Chen Zhaoyang <chenzhauyang@gmail.com>
> Date: Tue, 14 Feb 2023 23:56:26 -0600
> 
> After executing (python-shell-send-buffer) my point does not return to
> the mark but the beginning of the buffer. I am able to reproduce this
> behavior on "emacs -Q" (my emacs is "GNU Emacs 30.0.50 (build 11,
> x86_64-pc-linux-gnu, GTK+ Version 3.24.24, cairo version 1.16.0) of
> 2023-02-14"). I wrote a wrapper function like this
> 
> (defun site/python-shell-send-buffer ()
>   (interactive)
>   (save-excursion
>     (python-shell-send-buffer nil)))
> 
> which works as desired (??).

Please see

  https://debbugs.gnu.org/cgi/bugreport.cgi?bug=61463

it could be the same issue.  If it is, you will find a patch there.



^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: save-excursion not working for python-shell-send-buffer
  2023-02-15 13:24 ` Eli Zaretskii
@ 2023-02-15 14:23   ` Gregory Heytings
  2023-02-15 16:16   ` Chen Zhaoyang
  1 sibling, 0 replies; 4+ messages in thread
From: Gregory Heytings @ 2023-02-15 14:23 UTC (permalink / raw)
  To: Chen Zhaoyang; +Cc: Eli Zaretskii, help-gnu-emacs


>> After executing (python-shell-send-buffer) my point does not return to 
>> the mark but the beginning of the buffer. I am able to reproduce this 
>> behavior on "emacs -Q" (my emacs is "GNU Emacs 30.0.50 (build 11, 
>> x86_64-pc-linux-gnu, GTK+ Version 3.24.24, cairo version 1.16.0) of 
>> 2023-02-14"). I wrote a wrapper function like this
>>
>> (defun site/python-shell-send-buffer ()
>>   (interactive)
>>   (save-excursion
>>     (python-shell-send-buffer nil)))
>>
>> which works as desired (??).
>
> Please see
>
>  https://debbugs.gnu.org/cgi/bugreport.cgi?bug=61463
>
> it could be the same issue.  If it is, you will find a patch there.
>

Now that emacs-29 has been merged into master, the issue should be fixed 
there as well.  Can you please pull the latest changes and make bootstrap 
again?




^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: save-excursion not working for python-shell-send-buffer
  2023-02-15 13:24 ` Eli Zaretskii
  2023-02-15 14:23   ` Gregory Heytings
@ 2023-02-15 16:16   ` Chen Zhaoyang
  1 sibling, 0 replies; 4+ messages in thread
From: Chen Zhaoyang @ 2023-02-15 16:16 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: help-gnu-emacs

Eli Zaretskii <eliz@gnu.org> writes:

> Please see
>
>   https://debbugs.gnu.org/cgi/bugreport.cgi?bug=61463
>
> it could be the same issue.  If it is, you will find a patch there.

Thank you very much. I downloaded the patch. 

CZY



^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2023-02-15 16:16 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-02-15  5:56 save-excursion not working for python-shell-send-buffer Chen Zhaoyang
2023-02-15 13:24 ` Eli Zaretskii
2023-02-15 14:23   ` Gregory Heytings
2023-02-15 16:16   ` Chen Zhaoyang

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.