From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Artur Malabarba Newsgroups: gmane.emacs.help Subject: Re: Gnus + emacs.stackexchange Date: Mon, 11 May 2015 16:03:33 +0100 Message-ID: References: <87fv7hoxnd.fsf@debian.uxu> <87mw1luz3o.fsf_-_@debian.uxu> <87a8xjpxdh.fsf@gmail.com> <87oalyo7og.fsf@debian.uxu> <87zj5ghsiu.fsf@debian.uxu> <877fsh31d9.fsf@debian.uxu> <475a32e9-2edf-4aec-bcb6-5f4c693952ea@default> Reply-To: bruce.connor.am@gmail.com NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 X-Trace: ger.gmane.org 1431356634 4272 80.91.229.3 (11 May 2015 15:03:54 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 11 May 2015 15:03:54 +0000 (UTC) Cc: help-gnu-emacs , Emanuel Berg To: Drew Adams Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Mon May 11 17:03:53 2015 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1YrpFI-0000UB-9g for geh-help-gnu-emacs@m.gmane.org; Mon, 11 May 2015 17:03:52 +0200 Original-Received: from localhost ([::1]:38047 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YrpFH-0000ww-Na for geh-help-gnu-emacs@m.gmane.org; Mon, 11 May 2015 11:03:51 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:40182) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YrpF6-0000wV-98 for help-gnu-emacs@gnu.org; Mon, 11 May 2015 11:03:41 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YrpF0-0003VV-GI for help-gnu-emacs@gnu.org; Mon, 11 May 2015 11:03:40 -0400 Original-Received: from mail-la0-x234.google.com ([2a00:1450:4010:c03::234]:33005) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YrpF0-0003VH-7z for help-gnu-emacs@gnu.org; Mon, 11 May 2015 11:03:34 -0400 Original-Received: by layy10 with SMTP id y10so95316218lay.0 for ; Mon, 11 May 2015 08:03:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:reply-to:sender:in-reply-to:references:date:message-id :subject:from:to:cc:content-type; bh=E7/m3p2mLzje3wF7diWf01+phWR02bhb3yhkflTt8EQ=; b=oPLjPBZ6xjM9JpCSAMHtOCGEqxZXYgFewpTC8kZV9PWYUQQQnrV0Kj66v/otjtOVkK tCgqBK8dqh4ETDLgs/4SkcBPTSBDXAp2ZGWDBjeGqosc2eF5rnfyy3djpazDCCPE147/ Kjzn/5pgnCi4pTG9iDkG/d4CYYDW/Z+LoFEkopKqXluwKk1sAERKm4xDiUuS0hHgWMVz I+pf4dOFFucu1RqJR7Oa1Gyv1XjNUVELXjFXF2tnI1u/MMsRsqbf1AczTZ7Qvp/QwFni 56JLWHlo18+jkg+EOrPZ3fGzjCyWr6reDcSMxG+GNFrUsiuk33CqZV3wGpTuIckkzlHx d5Tw== X-Received: by 10.152.2.227 with SMTP id 3mr8096002lax.73.1431356613380; Mon, 11 May 2015 08:03:33 -0700 (PDT) Original-Received: by 10.25.150.1 with HTTP; Mon, 11 May 2015 08:03:33 -0700 (PDT) In-Reply-To: <475a32e9-2edf-4aec-bcb6-5f4c693952ea@default> X-Google-Sender-Auth: TPKwY9RpO-k2QpsiDRBJhvmusMc X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2a00:1450:4010:c03::234 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:104376 Archived-At: 2015-05-11 14:54 GMT+01:00 Drew Adams : >> >>> (wrong-type-argument char-or-string-p nil) in >> >>> tabulated-list-print >> >> >> >> Ok, would you be willing to produce a backtrace? >> >> (with M-x toggle-debug-on-error) >> > >> > This is what it says for `sx-search': >> > >> > Debugger entered--Lisp error: (wrong-type-argument char-or- >> > string-p nil) >> > tabulated-list-print-fake-header() >> > tabulated-list-print(remember) >> >> Ok. It looks like something is setting your >> `tabulated-list-use-header-line' variable to nil *between* the >> buffer initialization and the list printing. So the >> `tabulated-list--header-string' variable doesn't get set (it's >> normally set during buffer initialization), but when it's time to >> print, the variable is expected to be a string. >> I think that's a bug in tabulated-list-mode (which I'll try to get >> fixed now), but do you have any hooks or advices that may be causing >> that? > > Check where you call the major (derived) mode, which calls > `tabulated-list-mode'. If it calls it after you have already > inserted the header line then that line will be removed when > `tabulated-list-mode' (calls `special-mode' which) kills all > local variables. Activating the mode is the first thing we do on a new buffer. All variables are set after that. And sx has no reference to `tabulated-list-use-header-line' or `tabulated-list--header-string', which is why I suspect there's a hook gone rogue somewhere. Of course, I may be wrong. > IMO, the `tabulated-list-mode' doc is not clear about such > things. Put differently, the design of `tabulated-list-mode' > seems to be a bit fragile. You need to do things in a specific > order, which is not well documented. > > Caveat: I'm no expert on `tabulated-list-mode'. Just starting > to wade through it myself, actually - which is why I think I > recognize the above error. When I understand it better I will > perhaps file a bug report or two - doc or otherwise. I never had huge problems with this when writing paradox or sx.el. That said, I was following the lead of `package-menu-mode's definition, so I can't say how clear the documentation is on its own. But I do think it's a bug that tabulated-list just barfs if the user changes a variable to a legal value (even if it's done at the wrong time). So I'll be fixing that this week.