From: Stefan Monnier <monnier@iro.umontreal.ca>
Cc: emacs-devel@gnu.org
Subject: Re: emacs.py: catch all errors in eargs()
Date: Wed, 30 Aug 2006 17:11:10 -0400 [thread overview]
Message-ID: <jwvac5mos2a.fsf-monnier+emacs@gnu.org> (raw)
In-Reply-To: <20060830184055.3A56.SLAWOMIR.NOWACZYK.847@student.lu.se> (Slawomir Nowaczyk's message of "Wed, 30 Aug 2006 19:06:37 +0200")
> The following patch ensures that _emacs_out sentinel is *always*
> printed, regardless of what "name" could be. This is necessary for
> proper handling of eldoc-mode in python.el
> Current code hangs emacs on my machine when I enable eldoc-mode and put
> point over non-function like "print".
Thanks, I'll lok at it. But this is large enough with previous
contributions that I'm beginning to feel like I should need until your legal
paperwork comes in before committing it.
> BTW, shouldn't it *always* be possible to interrupt emacs by C-g? In my
Yes.
> case even C-g doesn't work, I have to kill emacs... I assume
Looks like a bug in python.el where we fail to re-enable C-g before doing
the accept-process-output (C-g is disabled by inhibit-quit when running
timers and such). I installed the patch below which should fix it.
Stefan
Index: python.el
===================================================================
RCS file: /sources/emacs/emacs/lisp/progmodes/python.el,v
retrieving revision 1.45
diff -u -u -b -r1.45 python.el
--- python.el 28 Aug 2006 21:58:27 -0000 1.45
+++ python.el 30 Aug 2006 21:09:30 -0000
@@ -1599,6 +1599,8 @@
instance. Assumes an inferior Python is running."
(let ((symbol (with-syntax-table python-dotty-syntax-table
(current-word))))
+ ;; This is run from timers, so inhibit-quit tends to be set.
+ (with-local-quit
;; First try the symbol we're on.
(or (and symbol
(python-send-receive (format "emacs.eargs(%S, %s)"
@@ -1616,7 +1618,7 @@
(python-send-receive
(format "emacs.eargs(%S, %s)"
(buffer-substring-no-properties (point) point)
- python-imports)))))))))))
+ python-imports))))))))))))
\f
;;;; Info-look functionality.
next prev parent reply other threads:[~2006-08-30 21:11 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-08-30 17:06 emacs.py: catch all errors in eargs() Slawomir Nowaczyk
2006-08-30 21:11 ` Stefan Monnier [this message]
2006-08-31 11:19 ` Slawomir Nowaczyk
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=jwvac5mos2a.fsf-monnier+emacs@gnu.org \
--to=monnier@iro.umontreal.ca \
--cc=emacs-devel@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.