unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Tassilo Horn <tsdh@gnu.org>
To: Lars Ingebrigtsen <larsi@gnus.org>
Cc: 40775@debbugs.gnu.org
Subject: bug#40775: 28.0.50; dns-query sometimes infloops
Date: Thu, 28 Jan 2021 12:19:14 +0100	[thread overview]
Message-ID: <87h7n1fgft.fsf@gnu.org> (raw)
In-Reply-To: <87eesfsaik.fsf@gnu.org>

References: <87eesfsaik.fsf@gnu.org> <87zhb2ywld.fsf@gnu.org> <87sg6l1req.fsf@gnus.org>
User-agent: mu4e 1.5.7; emacs 28.0.50
In-reply-to: <87sg6l1req.fsf@gnus.org>
Hi Lars,

>> For example, for me with emacs -Q
>>
>>   (benchmark-run 1
>>     (dns-query "_avatars-sec._tcp.zjp.codes" 'SRV)
>>     (dns-query "_avatars._tcp.zjp.codes" 'SRV))
>>
>> consistently takes 20 seconds, 10 seconds for each (unsuccessful)
>> query.  Those queries will be performed for every foo@zjp.codes mail
>> address in a message.
>
> These lookups should now be cached, so the delay should only happen
> the first time, which should help some.

The above benchmark is now twice as fast taking 10 seconds each time I
run it.

> And all the lookups should be asynchronous, I think, so there should
> be no hangs.  (If I remember correctly.)

Yes, seems like gravatar.el now does asynchronous lookups.

> So I think everything in this bug report should work better now?  Are
> you still seeing problems in this area (if you're still using
> libravatar)?

I'm using the default, so gravatar now.  I've now tried with

--8<---------------cut here---------------start------------->8---
(setq gravatar-service 'libravatar)
(gravatar-retrieve "foobar@zjp.codes" (lambda (g &rest args)
                                        (message "GRAVATAR: %S" g)))
--8<---------------cut here---------------end--------------->8---

which doesn't seem to block but pollutes the *Messages* buffer with
stuff like

--8<---------------cut here---------------start------------->8---
(fn STATUS)" nil t] 11 "

(fn URL)"] "r=g&d=404&s=32" format "%s/%s?%s" gravatar-hash] 7 "

(fn URL)"] "zjp.codes" ((("_avatars-sec" . "https") ("_avatars" . "http"))) (#2) inhibit-changing-match-data mapcar #[257 "A\"" [dns-get data] 4 "

(fn RECORD)"] dns-get answers #[257 "\"" [dns-get priority] 4 "
--8<---------------cut here---------------end--------------->8---

Not sure if it would do that when being used "normally", i.e., by Gnus
or some other client.

Anyway, in either case, it doesn't block anymore.  Feel free to close
the bug.

Bye,
Tassilo





  parent reply	other threads:[~2021-01-28 11:19 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-04-22 17:20 bug#40775: 28.0.50; dns-query sometimes infloops Tassilo Horn
2020-04-23 16:51 ` Tassilo Horn
2021-01-28  6:55   ` Lars Ingebrigtsen
2021-01-28 11:19 ` Tassilo Horn [this message]
2021-01-28 12:11   ` Lars Ingebrigtsen

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

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87h7n1fgft.fsf@gnu.org \
    --to=tsdh@gnu.org \
    --cc=40775@debbugs.gnu.org \
    --cc=larsi@gnus.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 public inbox

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

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).