GNU bug report logs -
#28492
27.0.50; File mode specification error for some files during desktop-read
Previous Next
Reported by: Kaushal Modi <kaushal.modi <at> gmail.com>
Date: Mon, 18 Sep 2017 13:59:01 UTC
Severity: normal
Fixed in version 27.0.50
Done: Kaushal Modi <kaushal.modi <at> gmail.com>
Bug is archived. No further changes may be made.
To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 28492 in the body.
You can then email your comments to 28492 AT debbugs.gnu.org in the normal way.
Toggle the display of automated, internal messages from the tracker.
Report forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#28492
; Package
emacs
.
(Mon, 18 Sep 2017 13:59:01 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
Kaushal Modi <kaushal.modi <at> gmail.com>
:
New bug report received and forwarded. Copy sent to
bug-gnu-emacs <at> gnu.org
.
(Mon, 18 Sep 2017 13:59:01 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
Hello,
To start off, this issue is not specific to emacs 27. I have been noticing
this issue for maybe one or two weeks and just to formally reporting it.
Issue: When doing desktop-read, only files from a certain project root
cause these errors:
File mode specification error: (wrong-type-argument stringp nil) [2
times]
Digging deeper, it looks like the set-auto-mode call in normal-mode is
returning nil. But it is surprising because the files for which this error
shows up does actually have an associated major mode (verilog-mode).
After the desktop loads, I am able to see the files that flagged that error
properly in the correct major mode though.
Here is the error backtrace:
(*I have replaced the actual path with /my/prj/root/some.file for the
purpose of corporate privacy. The some.file is has verilog-mode as its
major mode.)
Debugger entered--Lisp error: "File mode specification error:
(wrong-type-argument stringp nil)"
#<subr message>("File mode specification error: %s" (wrong-type-argument
stringp nil))
apply(#<subr message> ("File mode specification error: %s"
(wrong-type-argument stringp nil)))
message("File mode specification error: %s" (wrong-type-argument stringp
nil))
normal-mode(t)
after-find-file(nil nil)
find-file-noselect-1(#<buffer some.file> "/my/prj/root/some.file" :nowarn
nil "/my/prj/root/some.file" (96434279 175))
find-file-noselect("/my/prj/root/some.file" :nowarn)
desktop-restore-file-buffer("/my/prj/root/some.file" "some.file" nil)
desktop-create-buffer(208 "/my/prj/root/some.file" "some.file"
verilog-mode (abbrev-mode override-global-mode modi-mode beacon-mode
hi-lock-mode volatile-highlights-mode hungry-delete-mode
rainbow-delimiters-mode undo-tree-mode projectile-mode hardcore-mode
ivy-mode which-key-mode flyspell-mode yas-minor-mode auto-complete-mode
mode-line-space-mode) 6362 (19911 nil) t nil ((buffer-display-time 22952
2660 236587 832000) (buffer-file-coding-system . undecided-unix))
((mark-ring (19911))))
eval-buffer(#<buffer *load*-734956> nil
"/home/kmodi/.emacs.d/emacs_27_0.desktop" nil t) ; Reading at buffer
position 67828
In GNU Emacs 27.0.50 (build 1, x86_64-pc-linux-gnu, GTK+ Version 2.24.23)
of 2017-09-16
Repository revision: 977cd6cb28a37744966ec62f70cf62659f6f302a
Windowing system distributor 'The X.Org Foundation', version 11.0.60900000
System Description: Red Hat Enterprise Linux Workstation release 6.6
(Santiago)
Recent messages:
For information about GNU Emacs and the GNU system, type C-h C-a.
Configured using:
'configure --with-modules
--prefix=/home/kmodi/usr_local/apps/6/emacs/master
'--program-transform-name=s/^ctags$/ctags_emacs/'
'CPPFLAGS=-I/home/kmodi/usr_local/6/include -I/usr/include/freetype2
-I/usr/include' 'CFLAGS=-ggdb3 -O0' 'CXXFLAGS=-ggdb3 -O0'
'LDFLAGS=-L/home/kmodi/usr_local/6/lib -L/home/kmodi/usr_local/6/lib64
-ggdb3'
PKG_CONFIG_PATH=/home/kmodi/usr_local/6/lib/pkgconfig:/home/kmodi/usr_local/6/lib64/pkgconfig:/cad/adi/apps/gnu/linux/x86_64/6/lib/pkgconfig:/cad/adi/apps/gnu/linux/x86_64/6/lib64/pkgconfig:/usr/lib/pkgconfig:/usr/lib64/pkgconfig:/usr/share/pkgconfig:/lib/pkgconfig:/lib64/pkgconfig'
Configured features:
XPM JPEG TIFF GIF PNG RSVG IMAGEMAGICK SOUND GPM DBUS GSETTINGS NOTIFY
ACL LIBSELINUX GNUTLS LIBXML2 FREETYPE LIBOTF XFT ZLIB
TOOLKIT_SCROLL_BARS GTK2 X11 MODULES
Important settings:
value of $LANG: en_US.UTF-8
value of $XMODIFIERS: @im=none
locale-coding-system: utf-8-unix
Major mode: Lisp Interaction
Minor modes in effect:
tooltip-mode: t
global-eldoc-mode: t
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
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
Load-path shadows:
None found.
Features:
(shadow sort mail-extr emacsbug message subr-x puny seq byte-opt gv
bytecomp byte-compile cconv cl-loaddefs cl-lib dired dired-loaddefs
format-spec rfc822 mml easymenu mml-sec password-cache epa derived epg
epg-config gnus-util rmail rmail-loaddefs mm-decode mm-bodies mm-encode
mail-parse rfc2231 mailabbrev gmm-utils mailheader sendmail rfc2047
rfc2045 ietf-drums mm-util mail-prsvr mail-utils elec-pair time-date
mule-util tooltip eldoc electric uniquify ediff-hook vc-hooks
lisp-float-type mwheel term/x-win x-win term/common-win x-dnd tool-bar
dnd fontset image regexp-opt fringe tabulated-list replace newcomment
text-mode elisp-mode lisp-mode prog-mode register page menu-bar
rfn-eshadow isearch timer select scroll-bar mouse jit-lock font-lock
syntax facemenu font-core term/tty-colors 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 composite charscript charprop
case-table epa-hook jka-cmpr-hook help simple abbrev obarray 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 move-toolbar gtk
x-toolkit x multi-tty make-network-process emacs)
Memory information:
((conses 16 97100 8003)
(symbols 48 20813 1)
(miscs 40 46 119)
(strings 32 28798 1799)
(string-bytes 1 765072)
(vectors 16 14942)
(vector-slots 8 508712 6478)
(floats 8 48 68)
(intervals 56 245 0)
(buffers 992 11)
(heap 1024 29158 859))
--
Kaushal Modi
[Message part 2 (text/html, inline)]
Reply sent
to
Kaushal Modi <kaushal.modi <at> gmail.com>
:
You have taken responsibility.
(Mon, 18 Sep 2017 14:37:02 GMT)
Full text and
rfc822 format available.
Notification sent
to
Kaushal Modi <kaushal.modi <at> gmail.com>
:
bug acknowledged by developer.
(Mon, 18 Sep 2017 14:37:02 GMT)
Full text and
rfc822 format available.
Message #10 received at 28492-done <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
Sorry about the noise.
Turns out that a string-match-p was doing with a nil values variable in a
function I added to the verilog-mode-hook. (And that variable was
evaluating to nil only for a particular project.)
The error backtrace was confusing though.. it looked like set-auto-mode was
throwing the error.
But actually it was
set-auto-mode
- set-auto-mode-0
- (funcall mode)
- run-hooks .. (running the major mode hook)
- One of the functions in that hook
Is there a way so that an error like
Error in one of the functions in verilog-mode-hook while running
some.file
gets printed instead of a misleading message that doesn't even mention the
file causing it:
File mode specification error: (wrong-type-argument stringp nil)
--
Kaushal Modi
[Message part 2 (text/html, inline)]
bug archived.
Request was from
Debbugs Internal Request <help-debbugs <at> gnu.org>
to
internal_control <at> debbugs.gnu.org
.
(Tue, 17 Oct 2017 11:24:07 GMT)
Full text and
rfc822 format available.
This bug report was last modified 7 years and 302 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.