From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Tim Landscheidt Newsgroups: gmane.emacs.bugs Subject: bug#29023: 25.3; newsticker: Inconsistent documentation of newsticker-new-item-functions Date: Fri, 27 Oct 2017 05:18:41 +0000 Organization: http://www.tim-landscheidt.de/ Message-ID: <8760b1p3ri.fsf@passepartout.tim-landscheidt.de> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Trace: blaine.gmane.org 1509081619 11808 195.159.176.226 (27 Oct 2017 05:20:19 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Fri, 27 Oct 2017 05:20:19 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.3 (gnu/linux) To: 29023@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Fri Oct 27 07:20:12 2017 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1e7x3x-0001tL-JR for geb-bug-gnu-emacs@m.gmane.org; Fri, 27 Oct 2017 07:20:09 +0200 Original-Received: from localhost ([::1]:55781 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1e7x43-0001H9-G0 for geb-bug-gnu-emacs@m.gmane.org; Fri, 27 Oct 2017 01:20:15 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:38695) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1e7x3u-0001Cx-2M for bug-gnu-emacs@gnu.org; Fri, 27 Oct 2017 01:20:10 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1e7x3q-0005nS-7W for bug-gnu-emacs@gnu.org; Fri, 27 Oct 2017 01:20:06 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:55421) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1e7x3q-0005nC-3a for bug-gnu-emacs@gnu.org; Fri, 27 Oct 2017 01:20:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1e7x3p-0006De-N8; Fri, 27 Oct 2017 01:20:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Tim Landscheidt Original-Sender: "Debbugs-submit" Resent-CC: ulf.jasper@web.de, bug-gnu-emacs@gnu.org Resent-Date: Fri, 27 Oct 2017 05:20:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 29023 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: X-Debbugs-Original-To: bug-gnu-emacs@gnu.org X-Debbugs-Original-Xcc: Ulf Jasper Original-Received: via spool by submit@debbugs.gnu.org id=B.150908155323838 (code B ref -1); Fri, 27 Oct 2017 05:20:01 +0000 Original-Received: (at submit) by debbugs.gnu.org; 27 Oct 2017 05:19:13 +0000 Original-Received: from localhost ([127.0.0.1]:35868 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1e7x32-0006CQ-Sm for submit@debbugs.gnu.org; Fri, 27 Oct 2017 01:19:13 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:47373) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1e7x31-0006CB-P4 for submit@debbugs.gnu.org; Fri, 27 Oct 2017 01:19:12 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1e7x2v-0004lw-Kt for submit@debbugs.gnu.org; Fri, 27 Oct 2017 01:19:06 -0400 Original-Received: from lists.gnu.org ([2001:4830:134:3::11]:50920) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1e7x2v-0004lm-I4 for submit@debbugs.gnu.org; Fri, 27 Oct 2017 01:19:05 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:38329) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1e7x2u-0000wq-F5 for bug-gnu-emacs@gnu.org; Fri, 27 Oct 2017 01:19:05 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1e7x2r-0004gr-A5 for bug-gnu-emacs@gnu.org; Fri, 27 Oct 2017 01:19:04 -0400 Original-Received: from mezzogiorno.tim-landscheidt.de ([78.47.87.37]:33423) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1e7x2r-0004Yu-3D for bug-gnu-emacs@gnu.org; Fri, 27 Oct 2017 01:19:01 -0400 Original-Received: from x4e369cab.dyn.telefonica.de ([78.54.156.171]:50054 helo=passepartout.tim-landscheidt.de) by mezzogiorno.tim-landscheidt.de with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1e7x2c-0006NC-Qf for bug-gnu-emacs@gnu.org; Fri, 27 Oct 2017 05:18:46 +0000 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:139050 Archived-At: (newsticker) Automatic Processing says: | [=E2=80=A6] | In order to do so write a function which takes three arguments | FEED | the name of the corresponding news feed, | TITLE | the title of the headline, | DESC | the decoded description of the headline. | and add it to =E2=80=98newsticker-new-item-functions=E2=80=99. [=E2= =80=A6] newsticker-new-item-functions's docstring says: | List of functions run after a new headline has been retrieved. | Each function is called with the following three arguments: | FEED the name of the corresponding news feed, | TITLE the title of the headline, | DESC the decoded description of the headline. However the functions "Hook samples" in newst-backend.el are all defined as: | [=E2=80=A6] | (defun newsticker-new-item-functions-sample (feed item) | [=E2=80=A6] | (defun newsticker-download-images (feed item) | [=E2=80=A6] | (defun newsticker-download-enclosures (feed item) | [=E2=80=A6] i. e. they take two arguments, not three. Also, there is no explicit documentation if the functions' return values matter (AFAIUI they are ignored). In addition, newsticker-new-item-functions's docstring re- commends: | [=E2=80=A6] | See =E2=80=98newsticker-download-images=E2=80=99, and | =E2=80=98newsticker-download-enclosures=E2=80=99 for sample functions. | [=E2=80=A6] It might be useful to add newsticker-new-item-functions-*sample* to that list :-).