unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Eli Zaretskii <eliz@gnu.org>
To: "N. Jackson" <nljlistbox2@gmail.com>, martin rudalics <rudalics@gmx.at>
Cc: 33654@debbugs.gnu.org
Subject: bug#33654: 27.0.50; No record of init file errors printed in *Messages*
Date: Sat, 08 Dec 2018 12:46:21 +0200	[thread overview]
Message-ID: <83wook47pe.fsf@gnu.org> (raw)
In-Reply-To: <87o99xe032.fsf@moondust.localdomain> (nljlistbox2@gmail.com)

> From: "N. Jackson" <nljlistbox2@gmail.com>
> Cc: 33654@debbugs.gnu.org
> Date: Fri, 07 Dec 2018 12:08:33 -0500
> 
> I think, perhaps, that if something were written to *Messages* to inform
> the user that there was a warning/error, and to direct them to the
> *Warnings* buffer for details, it would make it less likely that the
> user would miss the information altogether. Something like
> 
>   An initialization error occurred -- see *Warnings* buffer for details.

Don't we already use the echo area to show the error itself?

> Also, the frame that was split to display the *Warnings* buffer was not
> the one that had the focus when Emacs finished starting up. (Indeed, I
> think it might have been on the most deeply buried frame.) There is a
> very high probability I would never see a warning/error displayed so
> obscurely.
> 
> It would seem that it would be better, if it were feasible, if the
> *Warnings* buffer could be displayed in a window on the frame that
> has the focus after Emacs finishes starting up.
> 
> 
> DETAILS
> 
> Here is a detailed example of the problem. I think this might have
> really happened to me in real life (resulting in Bug##33536 [1]).
> 
> Scenario: I have a notion that it would be a good idea to remove and
> then re-install an Emacs package. I decide that to be sure that none of
> it still hanging around in memory, I should exit an restart Emacs
> between removing the package and reinstalling it. The package in this
> case happens to be bbdb from Gnu Elpa. I have
> 
>   (bbdb-initialize 'gnus 'message)
> 
> in my init file.
> 
> When Emacs starts after bbdb has been uninstalled, the above line
> results in an error. A *Warnings* buffer is displayed as follows:
> 
>   Warning (initialization): An error occurred while loading `/home/nlj/.emacs':
> 
>   Symbol's function definition is void: bbdb-initialize
> 
>   To ensure normal operation, you should investigate and remove the
>   cause of the error in your initialization file.  Start Emacs with
>   the `--debug-init' option to view a complete error backtrace.
> 
> But I don't see this error/warning message because I don't visit the
> frame on which it is displayed. After all, it's just going to be a short
> Emacs session during which all I'm going to do is install bbdb.

I'm not sure we can guarantee that the frame showing *Warnings* is
always on top, since user initialization can create any number of
frames.  Maybe Martin has some tricks up his sleeves?

> In my *Messages* buffer is displayed:
> 
>   Loading cua-base...done
>   Loading delsel...done
>   Loading desktop...done
>   Loading battery...done
>   Loading time...done
>   Loading elec-pair...done
>   Loading saveplace...done
>   Loading savehist...done
>   Loading paren...done
>   Loading /home/nlj/.recentf...done
>   Cleaning up the recentf list...done (0 removed)
>   Starting new Ispell process /usr/bin/aspell with default dictionary...
>   Loading dired-x...done
>   Setting up indent for shell type sh
>   Indentation variables are now local.
>   Indentation setup for shell type sh
>   Ispell process killed
>   Starting new Ispell process /usr/bin/aspell with default dictionary...
>   Setting up indent for shell type sh
>   Indentation variables are now local.
>   Indentation setup for shell type sh
>   Omitting...
>   Omitted 384 lines.
>   uncompressing de.map.gz...done
>   Wrote /data/projects/vc/emacs/git/emacs/.emacs.desktop.lock
>   Desktop: 7 frames, 54 buffers restored.
>   For information about GNU Emacs and the GNU system, type C-h C-a.
> 
> This shows no indication of the initialization error.

Delayed warnings are not written to *Messages*, they are written to
*Warnings* instead.  This is so they don't get discarded if *Messages*
gets too long.  You just need to become accustomed to look in
*Warnings* as you are already accustomed to look in *Messages* (which
by default is not shown in any window, right?).

> Now it might be a user error to look for an indication of start up
> problems only in *Messages*, and it might a user error to miss the
> *Warnings* buffer, but I think it would improve Emacs, were it feasible,
> if it helped the user to avoid these mistakes by mentioning the
> error/warning in *Messages*, and by displaying the *Warnings* buffer in
> a frame that isn't buried.

Mentioning that in *Messages* is problematic, as it could disappear
without a trace.  I think.





  reply	other threads:[~2018-12-08 10:46 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-12-07  0:42 bug#33654: 27.0.50; No record of init file errors printed in *Messages* N. Jackson
2018-12-07  7:13 ` Eli Zaretskii
2018-12-07 17:08   ` N. Jackson
2018-12-08 10:46     ` Eli Zaretskii [this message]
2018-12-08 18:51       ` martin rudalics
2018-12-08 19:24         ` Eli Zaretskii
2018-12-09  8:26           ` martin rudalics
2020-10-11  1:54             ` Lars Ingebrigtsen
2021-05-11 13:49               ` 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=83wook47pe.fsf@gnu.org \
    --to=eliz@gnu.org \
    --cc=33654@debbugs.gnu.org \
    --cc=nljlistbox2@gmail.com \
    --cc=rudalics@gmx.at \
    /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).