Subject: bug#23592: 25.0.94; Emacs (and/or Gnus interaction) not resolving hostnames

From: Live System User <[email-masked]>
Date: Sat, 21 May 2016 04:38:23 -0400

Hi,

It appears that Gnus doesn't remember that a previously opened
IMAP server was opened and accessible.

I started up Gnus and it failed to access my IMAP mailbox.  The
*Messages* buffer contained:

Warning: Opening nnimap server on aol...failed: ; Unable to open server
nnimap+aol due to: imap.aim.com/993 No address associated with hostname

In the *Group* buffer, I then type "^" (gnus-group-enter-server-mode)
and it shows:

     {nnimap:aol} (denied)

I then type "O" (gnus-server-open-server) and Gnus connects to the
server:

     {nnimap:aol} (opened)

The *Messages* buffer contains:

Opening connection to imap.aim.com via tls...
auth-source-search: found 1 CACHED results matching (:max 1 :host ("aol" "imap.aim.com") :port (993 "imaps" "imap" "993" "143") :user "nyc4bos" :require (:user :secret) :create t)
auth-source-netrc-saver: found previous run for key ~/.authinfo.gpg db8969e569f4db5b74c76ff5fa70d316, returning
Opening connection to imap.aim.com...done

The *imap-log* buffer contains:

02:39:24 [imap.aim.com] (inhibited)
02:39:24 [imap.aim.com] 160 CAPABILITY

1. Unlike Bug# , this error message says:

        imap.aim.com/993 No address associated with hostname

   which is a valid,FQDN.

2. Why does a subsequent (gnus-server-open-server) command executed
   after a connection failure succeed in accessing the IMAP server?
   It is presumably using the same connection credentials (utilizing
   authsource.el) as when it failed.

   What is being done differently than when Gnus is first started?

3. After quiting Gnus (gnus-group-exit), and immediately restarting
   Gnus, I still get the "Unable to open server..." message.

   If it *just* connected to the server, why can't immediately
   connect again?  And since it subsequently connected successfully,
   why does it still warn "No address associated with hostname"

Thanks.

In GNU Emacs 25.0.94.1 (x86_64-redhat-linux-gnu, GTK+ Version 3.18.9)
 of 2016-05-18 built on copr-builder-587584625.novalocal
Windowing system distributor 'Fedora Project', version 11.0.11799901
Configured using:
 'configure --build=x86_64-redhat-linux-gnu
 --host=x86_64-redhat-linux-gnu --program-prefix=
 --disable-dependency-tracking --prefix=/usr --exec-prefix=/usr
 --bindir=/usr/bin --sbindir=/usr/sbin --sysconfdir=/etc
 --datadir=/usr/share --includedir=/usr/include --libdir=/usr/lib64
 --libexecdir=/usr/libexec --localstatedir=/var
 --sharedstatedir=/var/lib --mandir=/usr/share/man
 --infodir=/usr/share/info --with-dbus --with-gif --with-jpeg --with-png
 --with-rsvg --with-tiff --with-xft --with-xpm --with-x-toolkit=gtk3
 --with-gpm=no --with-xwidgets build_alias=x86_64-redhat-linux-gnu
 host_alias=x86_64-redhat-linux-gnu 'CFLAGS=-DMAIL_USE_LOCKF -O2 -g
 -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2
 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4
 -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1
 -m64 -mtune=generic' LDFLAGS=-Wl,-z,relro
 PKG_CONFIG_PATH=:/usr/lib64/pkgconfig:/usr/share/pkgconfig'

Configured features:
XPM JPEG TIFF GIF PNG RSVG IMAGEMAGICK SOUND DBUS GCONF GSETTINGS NOTIFY
ACL LIBSELINUX GNUTLS LIBXML2 FREETYPE M17N_FLT LIBOTF XFT ZLIB
TOOLKIT_SCROLL_BARS GTK3 X11 XWIDGETS

Important settings:
  value of $LANG: en_US.UTF-8
  value of $XMODIFIERS: @im=ibus
  locale-coding-system: utf-8-unix

Major mode: Fundamental

Minor modes in effect:
  tooltip-mode: t
  global-eldoc-mode: t
  electric-indent-mode: t
  mouse-wheel-mode: t
  tool-bar-mode: t
  menu-bar-mode: t
  file-name-shadow-mode: t
  global-font-lock-mode: t
  blink-cursor-mode: t
  auto-composition-mode: t
  auto-encryption-mode: t
  auto-compression-mode: t
  line-number-mode: t
  transient-mark-mode: t

Recent messages:
Mark saved where search started
Mark set [3 times]
= is undefined [29 times]
Mark set
Opening connection to imap.aim.com via tls...
auth-source-search: found 1 CACHED results matching (:max 1 :host ("aol" "imap.aim.com") :port (993 "imaps" "imap" "993" "143") :user "nyc4bos" :require (:user :secret) :create t)
auth-source-netrc-saver: found previous run for key ~/.authinfo.gpg db8969e569f4db5b74c76ff5fa70d316, returning
Opening connection to imap.aim.com...done
Mark set [2 times]
Mark activated

Load-path shadows:
~/.emacs.d/lisp/ntlm hides /usr/share/emacs/25.0.94/lisp/net/ntlm

Features:
(shadow emacsbug misearch multi-isearch pp thingatpt mailalias smtpmail
sendmail flow-fill shr-color color gnus-dup sort gnus-cite smiley
ansi-color shr dom subr-x browse-url qp mail-extr gnus-bcklg gnus-async
gnus-ml disp-table nnagent nnml cursor-sensor nndraft nnmh nndoc
mm-archive timezone url-http url-gw url-cache url-auth url-handlers
utf-7 rfc2104 nnfolder network-stream nsm starttls gnus-agent gnus-srvr
gnus-score score-mode nnvirtual gnus-msg nntp gnus-cache epa-file epa
nnreddit json map seq gnus-art mm-uu mml2015 mm-view mml-smime smime dig
sieve sieve-mode sieve-manage nnir gnus-sum gnus-group derived mm-url
url url-proxy url-privacy url-expand url-methods url-history url-cookie
url-domsuf url-util url-parse auth-source eieio byte-opt bytecomp
byte-compile cl-extra cconv eieio-core url-vars mailcap gnus-undo
gnus-start gnus-cloud nnimap cl-seq nnmail mail-source tls gnutls utf7
netrc parse-time gnus-spec gnus-int gnus-range message cl-macs dired
format-spec rfc822 mml mml-sec password-cache epg epg-config mm-decode
mm-bodies mm-encode mail-parse rfc2231 rfc2047 rfc2045 ietf-drums
mailabbrev gmm-utils mailheader gnus-win gnus gnus-ems wid-edit cl gv
nnoo nnheader gnus-util mm-util help-fns help-mode easymenu cl-loaddefs
pcase cl-lib mail-prsvr mail-utils time-date mule-util tooltip eldoc
electric uniquify ediff-hook vc-hooks lisp-float-type mwheel x-win
term/common-win x-dnd tool-bar dnd fontset image regexp-opt fringe
tabulated-list newcomment elisp-mode lisp-mode prog-mode register page
menu-bar rfn-eshadow timer select scroll-bar mouse jit-lock font-lock
syntax facemenu font-core frame cl-generic cham georgian utf-8-lang
misc-lang vietnamese tibetan thai tai-viet lao korean japanese eucjp-ms
cp51932 hebrew greek romanian slovak czech european ethiopic indian
cyrillic chinese charscript case-table epa-hook jka-cmpr-hook help
simple abbrev minibuffer cl-preloaded nadvice loaddefs button faces
cus-face macroexp files text-properties overlay sha1 md5 base64 format
env code-pages mule custom widget hashtable-print-readable backquote
dbusbind inotify dynamic-setting system-font-setting font-render-setting
xwidget-internal move-toolbar gtk x-toolkit x multi-tty
make-network-process emacs)

Memory information:
((conses 16 287403 23945)
 (symbols 48 123797 0)
 (miscs 40 133 325)
 (strings 32 96457 2216)
 (string-bytes 1 3465964)
 (vectors 16 24948)
 (vector-slots 8 679663 28881)
 (floats 8 572 992)
 (intervals 56 1020 101)
 (buffers 976 58)
 (heap 1024 67490 522327))