From: "Cédric Chépied" <cedric.chepied@gmail.com>
To: emacs-devel <emacs-devel@gnu.org>
Subject: erc-format-nick and znc
Date: Wed, 30 Jul 2014 08:52:15 +0200 [thread overview]
Message-ID: <53d89620.620dc30a.1a18.6b04@mx.google.com> (raw)
Hi,
I'm using erc to connect to my znc server. I now have an error each time I need
to display buffer playback:
Debugger entered--Lisp error: (wrong-type-argument arrayp nil)
aref(nil 0)
(memq (aref user 0) cl-struct-erc-server-user-tags)
(and (memq (aref user 0) cl-struct-erc-server-user-tags))
(or (and (memq (aref user 0) cl-struct-erc-server-user-tags)) (error "%s accessing a non-%s" (quote erc-server-user-nickname) (quote erc-server-user)))
(progn (or (and (memq (aref user 0) cl-struct-erc-server-user-tags)) (error "%s accessing a non-%s" (quote erc-server-user-nickname) (quote erc-server-user))) (aref user 1))
(let ((nick (progn (or (and (memq (aref user 0) cl-struct-erc-server-user-tags)) (error "%s accessing a non-%s" (quote erc-server-user-nickname) (quote erc-server-user))) (aref user 1)))) (concat (erc-propertize (erc-get-user-mode-prefix nick) (quote face) (quote erc-nick-prefix-face)) nick))
erc-format-nick(nil nil)
erc-server-PRIVMSG(#<process erc-localhost-2121> [cl-struct-erc-response ":***!znc@znc.in PRIVMSG #gnaaaapouet :Buffer Playback..." "***!znc@znc.in" "PRIVMSG" ("#gnaaaapouet" "Buffer Playback...") "Buffer Playback..."])
run-hook-with-args-until-success(erc-server-PRIVMSG #<process erc-localhost-2121> [cl-struct-erc-response ":***!znc@znc.in PRIVMSG #gnaaaapouet :Buffer Playback..." "***!znc@znc.in" "PRIVMSG" ("#gnaaaapouet" "Buffer Playback...") "Buffer Playback..."])
erc-call-hooks(#<process erc-localhost-2121> [cl-struct-erc-response ":***!znc@znc.in PRIVMSG #gnaaaapouet :Buffer Playback..." "***!znc@znc.in" "PRIVMSG" ("#gnaaaapouet" "Buffer Playback...") "Buffer Playback..."])
erc-handle-parsed-server-response(#<process erc-localhost-2121> [cl-struct-erc-response ":***!znc@znc.in PRIVMSG #gnaaaapouet :Buffer Playback..." "***!znc@znc.in" "PRIVMSG" ("#gnaaaapouet" "Buffer Playback...") "Buffer Playback..."])
erc-parse-server-response(#<process erc-localhost-2121> ":***!znc@znc.in PRIVMSG #gnaaaapouet :Buffer Playback...")
erc-server-filter-function(#<process erc-localhost-2121> ":***!znc@znc.in PRIVMSG #gnaaaapouet :Buffer Playback...\n")
read-event(nil t 1)
sit-for(1)
(while (consp --cl-var--) (setq network (car --cl-var--)) (znc-erc network) (sit-for 1) (setq --cl-var-- (cons network --cl-var--)) (setq --cl-var-- (cdr --cl-var--)))
(let* ((--cl-var-- (znc-walk-all-servers :each (quote znc-endpoint-slug))) (network nil) (--cl-var-- nil)) (while (consp --cl-var--) (setq network (car --cl-var--)) (znc-erc network) (sit-for 1) (setq --cl-var-- (cons network --cl-var--)) (setq --cl-var-- (cdr --cl-var--))) (nreverse --cl-var--))
chep-all-erc()
I'm on master branch, commit 4d51f9c * ediff: Replace obsolete toggle-read-only
with read-only-mode
I fixed it with this code (just testing if user is non nil) and setting
erc-format-nick-function to my-erc-format-nick:
(defun my-erc-format-nick (&optional user _channel-data)
"Return the nickname of USER.
See also `erc-format-nick-function'."
(when user
(let ((nick (erc-server-user-nickname user)))
(concat (erc-propertize
(erc-get-user-mode-prefix nick)
'face 'erc-nick-prefix-face)
nick))))
--
Cédric Chépied
<cedric.chepied@gmail.com>
reply other threads:[~2014-07-30 6:52 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=53d89620.620dc30a.1a18.6b04@mx.google.com \
--to=cedric.chepied@gmail.com \
--cc=emacs-devel@gnu.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).