From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#54996: Emacs hangs when editing Python code with debug-on-error set to t Date: Mon, 18 Apr 2022 08:46:51 +0300 Message-ID: <83mtgjvt84.fsf@gnu.org> References: <87k0bnmoff.fsf@gnus.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="1494"; mail-complaints-to="usenet@ciao.gmane.io" Cc: rhstanton@berkeley.edu, 54996@debbugs.gnu.org To: Lars Ingebrigtsen Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Mon Apr 18 07:48:52 2022 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1ngKFn-0000DF-OL for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 18 Apr 2022 07:48:51 +0200 Original-Received: from localhost ([::1]:56104 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ngKFm-000731-93 for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 18 Apr 2022 01:48:50 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:35170) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ngKF0-00071n-LC for bug-gnu-emacs@gnu.org; Mon, 18 Apr 2022 01:48:03 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:43870) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1ngKF0-0006z8-CT for bug-gnu-emacs@gnu.org; Mon, 18 Apr 2022 01:48:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1ngKF0-0006k3-3p for bug-gnu-emacs@gnu.org; Mon, 18 Apr 2022 01:48:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 18 Apr 2022 05:48:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 54996 X-GNU-PR-Package: emacs Original-Received: via spool by 54996-submit@debbugs.gnu.org id=B54996.165026084225723 (code B ref 54996); Mon, 18 Apr 2022 05:48:02 +0000 Original-Received: (at 54996) by debbugs.gnu.org; 18 Apr 2022 05:47:22 +0000 Original-Received: from localhost ([127.0.0.1]:37767 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ngKEM-0006gp-4S for submit@debbugs.gnu.org; Mon, 18 Apr 2022 01:47:22 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:41758) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ngKEK-0006gc-Sr for 54996@debbugs.gnu.org; Mon, 18 Apr 2022 01:47:21 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]:37680) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ngKEF-0006ut-CE; Mon, 18 Apr 2022 01:47:15 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-version:References:Subject:In-Reply-To:To:From: Date; bh=/2C6GEhs6tActtMvmdUTxH+jIzGaiytcpzgDp6KyX6E=; b=FG9qne4Jo2E8l5YVh0u/ poaknmZKbamUhhnq89eJ6fowb0WEtllYQpY8zCEj0VQmXMAmJYGephuyZZuT4aum6z1DyWOudNv4D defJAbpkrqDmNL2dCttjxjejbzBXBmmUO1Q1nGPxurS3waQO0+Rw5rlBGgBLWX4enCSmAYesxvnCq JW+jOcysYOfUUiDMJw9A7bf1BbRlTNL72uCSlIdFpsIGhOucGld3xbAlFw5yuAQPfJ8KsE1XG+jjc OS0wcxanscczH0WxulkchvHl1wr/jH/31rUdrNiRsIcv0uP0mc5omkzBNE+UofWC3Ta+rTG+nzCN6 Od1a4A+Sl0fBVA==; Original-Received: from [87.69.77.57] (port=1631 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ngKE5-0001Da-M6; Mon, 18 Apr 2022 01:47:15 -0400 In-Reply-To: <87k0bnmoff.fsf@gnus.org> (message from Lars Ingebrigtsen on Sun, 17 Apr 2022 22:43:00 +0200) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:230142 Archived-At: > From: Lars Ingebrigtsen > Date: Sun, 17 Apr 2022 22:43:00 +0200 > Cc: 54996@debbugs.gnu.org > > Richard Stanton writes: > > > Put the cursor right at the start of the file, on the first double > > quote, and press ‘, the single quote character. On my machine, Emacs > > now hangs and doesn’t respond to the keyboard. Without debug-on-error, > > this works just fine. > > I can reproduce this, too (on Debian/bookworm). And I cannot reproduce at all. Does the recipe involve the Python interpreter in any way? If so, that might be the reason why it doesn't reproduce here. It is also not clear to me whether I should insert ‘ or ' (I tried both). > But it's bizarre that the debug-on-error setting should affect this. > I've skimmed through python.el looking for anything obvious (like a > `condition-case-unless-debug' but can't find anything). Calling a debugger triggers a redisplay cycle, and maybe that explains the problem. > The culprit must be in python-syntax-stringify -- if I just remove that, > the hang is gone. But there's no odd error handling there that I can > see (unless it's hiding in syntax-ppss)... anybody got any ideas? Catching a backtrace on the C level might explain what happens. But since I cannot reproduce the problem, I cannot show such a backtrace, either.