From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#34763: 27.0.50; url-retrieve-synchronously misbehaves inside eldoc-documentation-function Date: Fri, 15 Mar 2019 17:47:13 +0200 Message-ID: <83r2b8ywam.fsf@gnu.org> References: <83a7i15vrk.fsf@gnu.org> <787f765a-42f4-40d0-3b78-e751f546fe6c@yandex.ru> <831s3c3ta8.fsf@gnu.org> <8f7ae869-2e94-5535-f16f-476348036dc2@yandex.ru> <83r2bc2csd.fsf@gnu.org> <83h8c63ek1.fsf@gnu.org> <26aa8637-18db-2551-bff8-41276f22732b@yandex.ru> Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="244947"; mail-complaints-to="usenet@blaine.gmane.org" Cc: 34763@debbugs.gnu.org To: Dmitry Gutov Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Fri Mar 15 17:11:52 2019 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([209.51.188.17]) by blaine.gmane.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1h4pR1-0011bS-4z for geb-bug-gnu-emacs@m.gmane.org; Fri, 15 Mar 2019 17:11:51 +0100 Original-Received: from localhost ([127.0.0.1]:58197 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1h4pQz-0007B5-W3 for geb-bug-gnu-emacs@m.gmane.org; Fri, 15 Mar 2019 12:11:50 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:35575) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1h4pGe-0006wv-Ez for bug-gnu-emacs@gnu.org; Fri, 15 Mar 2019 12:01:09 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1h4p3z-0003Zn-HZ for bug-gnu-emacs@gnu.org; Fri, 15 Mar 2019 11:48:04 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:60069) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1h4p3x-0003Ym-Vq for bug-gnu-emacs@gnu.org; Fri, 15 Mar 2019 11:48:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1h4p3x-0006ez-QW for bug-gnu-emacs@gnu.org; Fri, 15 Mar 2019 11:48:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 15 Mar 2019 15:48:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 34763 X-GNU-PR-Package: emacs Original-Received: via spool by 34763-submit@debbugs.gnu.org id=B34763.155266486025566 (code B ref 34763); Fri, 15 Mar 2019 15:48:01 +0000 Original-Received: (at 34763) by debbugs.gnu.org; 15 Mar 2019 15:47:40 +0000 Original-Received: from localhost ([127.0.0.1]:45380 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1h4p3b-0006eH-Vc for submit@debbugs.gnu.org; Fri, 15 Mar 2019 11:47:40 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:48371) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1h4p3Z-0006e1-AR for 34763@debbugs.gnu.org; Fri, 15 Mar 2019 11:47:38 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]:42701) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1h4p3T-0003P1-Cg; Fri, 15 Mar 2019 11:47:31 -0400 Original-Received: from [176.228.60.248] (port=3021 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1h4p3S-0001G7-PF; Fri, 15 Mar 2019 11:47:31 -0400 In-reply-to: <26aa8637-18db-2551-bff8-41276f22732b@yandex.ru> (message from Dmitry Gutov on Fri, 15 Mar 2019 16:24:44 +0200) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 209.51.188.43 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.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:156393 Archived-At: > Cc: 34763@debbugs.gnu.org > From: Dmitry Gutov > Date: Fri, 15 Mar 2019 16:24:44 +0200 > > Sounds like an external library problem, maybe? GnuTLS? > > If you do the same from an interactive function, not from eldoc, does > > the problem happen there as well? > > More or less. I managed to make it slower by ~20x as well. > > Try this: > > (defun silly-eldoc () > (let ((start (time-to-seconds))) > (dotimes (i 10) > (url-retrieve-synchronously "http://www.google.com") > (message "try %i" i)) > (format "done in %f" (- (time-to-seconds) start)))) > > (defun silly-command () > (interactive) > (message "%s" (silly-eldoc))) > > (global-set-key (kbd "C-o") #'silly-command) > > Call the command a few time with C-o, it should run the timer and finish > with calculation how much time it took to run the requests. Now: > > 1. Alternate between pressing C-o and C-g, with varying speeds. > > The goal is to see > > error in process filter: Transfer interrupted! > error in process filter: url-http-generic-filter: Transfer interrupted! > > a few times. > > 2. Then see if C-o still runs to completion. If it does, and does not > look slow enough, repeat 1. So it sounds like quitting in the middle of a URL retrieval leaves some leftovers that get in the way of additional retrieval attempts. > BUT! I have tried to reproduce this slowdown behavior with a local > server, and so far no luck. Ping to Google (or almost any other website) > is 100ms from my current location, so maybe it makes a difference. Maybe with a local server you aren't fast enough to interrupt the transfer before it completes?