Re: nnir with notmuch gives error; sort: Wrong type argument: number-or-marker-p, nil

2020-03-15 Thread Eric Abrahamsen
physiculus  writes:

> Eric Abrahamsen  writes:
>
> Ok, here is the list. Hope it helps :-)
>

[...]

> /home/held/Maildirnm/karlderletzte/Sent/cur/1554294583.6ad7d1c538e8c734.shinri:2,,U=22:2,S!2,S
> /home/held/Maildirnm/karlderletzte/Sent/cur/1554294638.4676_1518.shinri,U=23!2,S

[...]

I haven't spent a whole lot of time with the maildir file format, but
neither of these look like legal maildir filenames to me. The first has
two colons, the second has none, and I don't know what's going on with
the exclamation marks. Even if they're legal I'll bet nnmaildir is
barfing on them. If you run:

(nnir-run-notmuch '((query . "Hock")) "nnmaildir:Lokal" '("karlderletzte/Sent"))

I would expect you to get something like this in *Messages*:

(["nnmaildir+Lokal:karlderletzte/Sent" nil 0]
 ["nnmaildir+Lokal:karlderletzte/Sent" nil 0]
 ["nnmaildir+Lokal:karlderletzte/Sent" nil 0])

Is that correct?

___
info-gnus-english mailing list
info-gnus-english@gnu.org
https://lists.gnu.org/mailman/listinfo/info-gnus-english


Re: nnir with notmuch gives error; sort: Wrong type argument: number-or-marker-p, nil

2020-03-15 Thread xuqi
physiculus  writes:

> Eric Abrahamsen  writes:
>
> Ok, here is the list. Hope it helps :-)
>
Unfortunately it doesn't in this case ;-) see my reply below:

> /home/held/Maildirnm/Privat/cur/1584002263.M785296P11519Q0.kubuntu:2,S
> /home/held/Maildirnm/Privat/cur/1584001757.M962421P11519Q0.kubuntu:2,
> /home/held/Maildirnm/Privat/cur/1584001970.M953224P11519Q0.kubuntu:2,
> /home/held/Maildirnm/Privat/cur/1584002264.M177070P11519Q0.kubuntu:2,S
> /home/held/Maildirnm/Privat/cur/1584002264.M570398P11519Q1.kubuntu:2,S
> /home/held/Maildirnm/karlderletzte/INBOX/cur/1554399542.4634_1560.shinri,U=651:2,S
> /home/held/Maildirnm/karlderletzte/Sent/cur/1554294583.6ad7d1c538e8c734.shinri:2,,U=22:2,S!2,S
>
>> physiculus  writes:
>>
>>> Eric Abrahamsen  writes:
>>>
>>> Hmmh, this looks different and with no errors.
>>> But is this in format, which gnus could read?
>>>
>>> the result is displayed in *Message* Buffer. Is this correct?
>>>
>>> Poulpoulsen
>>>
>>> Doing notmuch query Hock...
>>> notmuch args: search --format=text --output=files Hock
>>> Massaging notmuch output...done
>>> (["nnmaildir+Lokal:Privat" 349 0] ["nnmaildir+Lokal:Privat" 446 0]
>>> ["nnmaildir+Lokal:Privat" 506 0] ["nnmaildir+Lokal:Privat" 333 0]
>>> ["nnmaildir+Lokal:ZuErledigen" 399 0] ["nnmaildir+Lokal:ZuErledigen" 131
>>> 0] ["nnmaildir+Lokal:ZuErledigen" 226 0] ["nnmaildir+Lokal:Linzessin" 34
>>> 0] ["nnmaildir+Lokal:ZuErledigen" 318 0] ["nnmaildir+Lokal:ZuErledigen"
>>> 266 0] ["nnmaildir+Lokal:ZuErledigen" 42 0] ["nnmaildir+Lokal:logins"
>>> 156 0] ...)

It would help if we can see the complete list here. Unfortunately,
unless notmuch encounters a problem and value of `gnus-verbose' is > 6,
`nnir-tmp-buffer' would be erased. In your case notmuch runs perfectly
well.

However, after looking at the code of `nnir-retrieve-headers` more
closely, I think I narrowed down the range of possible courses a bit.

The offending line of code `(sort (mapcar 'cdr articleids) '<)` for one
of your searchs would translate into something like this:

   (sort (mapcar 'cdr (cadr 
'("nnmaildir+Lokal:Privat"
  ((1 . 349)
   (2 . 446)
   (3 . 506)
   (4 . 333) '<)

In this case it would run and give you the result:

   '(333 349 446 506)

But down the line, one or more of the articles would have ID(s) that are
nil. Maybe it's a file that's not properly synced. In the search result
it probably looks like this:

   ["nnmaildir+Lokal:SomeFolder" nil 0]

>>
>> That looks correct, but it would be important to see the whole list. Can
>> you still do the (switch-to-buffer nnir-tmp-buffer) and paste the
>> contents here?

As Eric mentioned, it is important to see the whole list. To get the
whole list generated by `nnir-run-notmuch', you can wrap your search
like this:

 (progn
  (setq xbuff (generate-new-buffer "*my output*"))
  (print (nnir-run-notmuch '((query . "hock")) "nnmaildir:Lokal") xbuff)
  (switch-to-buffer xbuff ))

Then you can copy the content of *my output* and paste it here. If
indeed there were some nils in the result, we should be able to find the
corresponding file using `nnmaildir-article-number-to-file-name' and
more elisp.

>>
>>
>> ___
>> info-gnus-english mailing list
>> info-gnus-english@gnu.org
>> https://lists.gnu.org/mailman/listinfo/info-gnus-english
>
> ___
> info-gnus-english mailing list
> info-gnus-english@gnu.org
> https://lists.gnu.org/mailman/listinfo/info-gnus-english


___
info-gnus-english mailing list
info-gnus-english@gnu.org
https://lists.gnu.org/mailman/listinfo/info-gnus-english


Re: nnir with notmuch gives error; sort: Wrong type argument: number-or-marker-p, nil

2020-03-15 Thread physiculus
Eric Abrahamsen  writes:

Ok, here is the list. Hope it helps :-)

/home/held/Maildirnm/Privat/cur/1584002263.M785296P11519Q0.kubuntu:2,S
/home/held/Maildirnm/Privat/cur/1584001757.M962421P11519Q0.kubuntu:2,
/home/held/Maildirnm/Privat/cur/1584001970.M953224P11519Q0.kubuntu:2,
/home/held/Maildirnm/Privat/cur/1584002264.M177070P11519Q0.kubuntu:2,S
/home/held/Maildirnm/Privat/cur/1584002264.M570398P11519Q1.kubuntu:2,S
/home/held/Maildirnm/karlderletzte/INBOX/cur/1554399542.4634_1560.shinri,U=651:2,S
/home/held/Maildirnm/karlderletzte/Sent/cur/1554294583.6ad7d1c538e8c734.shinri:2,,U=22:2,S!2,S
/home/held/Maildirnm/karlderletzte/Sent/cur/1554294638.4676_1518.shinri,U=23!2,S
/home/held/Maildirnm/karlderletzte/INBOX/cur/1554292397.3889_1547.shinri,U=645:2,RS
/home/held/Maildirnm/karlderletzte/Sent/cur/1554280492.2358_1468.shinri,U=21:2,S!2,S
/home/held/Maildirnm/Privat/cur/1547397044.22850_1.shinri:2,S
/home/held/Maildirnm/Privat/cur/1547397028.20987_1.shinri:2,S
/home/held/Maildirnm/Privat/cur/1547397075.26578_1.shinri:2,S
/home/held/Maildirnm/Privat/cur/1547397037.21967_1.shinri:2,S
/home/held/Maildirnm/Privat/cur/1547397034.21560_1.shinri:2,S
/home/held/Maildirnm/Privat/cur/1547397044.22861_1.shinri:2,S
/home/held/Maildirnm/Privat/cur/1547397079.27064_1.shinri:2,S
/home/held/Maildirnm/Privat/cur/1547397028.20899_1.shinri:2,S
/home/held/Maildirnm/Privat/cur/1547397040.22375_1.shinri:2,S
/home/held/Maildirnm/Privat/cur/1547397082.27482_1.shinri:2,S
/home/held/Maildirnm/ZuErledigen/cur/1547396223.5196_1.shinri:2,S
/home/held/Maildirnm/Privat/cur/1547397045.22919_1.shinri:2,S
/home/held/Maildirnm/Privat/cur/1547397045.22941_1.shinri:2,S
/home/held/Maildirnm/Privat/cur/1547397057.24413_1.shinri:2,S
/home/held/Maildirnm/Privat/cur/1547397076.26744_1.shinri:2,S
/home/held/Maildirnm/Privat/cur/1547397030.21141_1.shinri:2,S
/home/held/Maildirnm/Privat/cur/1547397064.25177_1.shinri:2,S
/home/held/Maildirnm/Privat/cur/1547397067.25588_1.shinri:2,S
/home/held/Maildirnm/Privat/cur/1547397051.23775_1.shinri:2,S
/home/held/Maildirnm/Privat/cur/1547397055.24309_1.shinri:2,S
/home/held/Maildirnm/Privat/cur/1547397047.23183_1.shinri:2,S
/home/held/Maildirnm/Privat/cur/1547397078.26964_1.shinri:2,S
/home/held/Maildirnm/Privat/cur/1547397069.25732_1.shinri:2,S
/home/held/Maildirnm/Privat/cur/1547397037.21978_1.shinri:2,S
/home/held/Maildirnm/ZuErledigen/cur/1547396236.6916_1.shinri:2,S
/home/held/Maildirnm/Privat/cur/1547397058.24491_1.shinri:2,S
/home/held/Maildirnm/Privat/cur/1547397042.22551_1.shinri:2,S
/home/held/Maildirnm/ZuErledigen/cur/1547396206.3050_1.shinri:2,S
/home/held/Maildirnm/ZuErledigen/cur/1547396221.4874_1.shinri:2,S
/home/held/Maildirnm/Privat/cur/1547397066.25422_1.shinri:2,S
/home/held/Maildirnm/ZuErledigen/cur/1547396228.5956_1.shinri:2,S
/home/held/Maildirnm/Privat/cur/1547397055.24234_1.shinri:2,S
/home/held/Maildirnm/Privat/cur/1547397058.24546_1.shinri:2,S
/home/held/Maildirnm/Privat/cur/1547397039.22155_1.shinri:2,S
/home/held/Maildirnm/Privat/cur/1547397049.23466_1.shinri:2,S
/home/held/Maildirnm/Privat/cur/1547397050.23598_1.shinri:2,S
/home/held/Maildirnm/logins/cur/1547396690.6373_1.shinri:2,S
/home/held/Maildirnm/logins/cur/1547396699.8236_1.shinri:2,S
/home/held/Maildirnm/ZuErledigen/cur/1547396195.1584_1.shinri:2,S
/home/held/Maildirnm/ZuErledigen/cur/1547396216.4287_1.shinri:2,S
/home/held/Maildirnm/ZuErledigen/cur/1547396221.4860_1.shinri:2,S
/home/held/Maildirnm/Linzessin/cur/1547396282.13712_1.shinri:2,S
/home/held/Maildirnm/ZuErledigen/cur/1547396213.3845_1.shinri:2,S
/home/held/Maildirnm/ZuErledigen/cur/1547396204.2775_1.shinri:2,S
/home/held/Maildirnm/ZuErledigen/cur/1547396227.5806_1.shinri:2,S
/home/held/Maildirnm/Privat/cur/1547397060.24778_1.shinri:2,S
/home/held/Maildirnm/Privat/cur/1547397079.27030_1.shinri:2,S
/home/held/Maildirnm/Privat/cur/1547397072.26225_1.shinri:2,S
/home/held/Maildirnm/Privat/cur/1547397062.24966_1.shinri:2,S

> physiculus  writes:
>
>> Eric Abrahamsen  writes:
>>
>> Hmmh, this looks different and with no errors.
>> But is this in format, which gnus could read?
>>
>> the result is displayed in *Message* Buffer. Is this correct?
>>
>> Poulpoulsen
>>
>> Doing notmuch query Hock...
>> notmuch args: search --format=text --output=files Hock
>> Massaging notmuch output...done
>> (["nnmaildir+Lokal:Privat" 349 0] ["nnmaildir+Lokal:Privat" 446 0]
>> ["nnmaildir+Lokal:Privat" 506 0] ["nnmaildir+Lokal:Privat" 333 0]
>> ["nnmaildir+Lokal:ZuErledigen" 399 0] ["nnmaildir+Lokal:ZuErledigen" 131
>> 0] ["nnmaildir+Lokal:ZuErledigen" 226 0] ["nnmaildir+Lokal:Linzessin" 34
>> 0] ["nnmaildir+Lokal:ZuErledigen" 318 0] ["nnmaildir+Lokal:ZuErledigen"
>> 266 0] ["nnmaildir+Lokal:ZuErledigen" 42 0] ["nnmaildir+Lokal:logins"
>> 156 0] ...)
>
> That looks correct, but it would be important to see the whole list. Can
> you still do the (switch-to-buffer nnir-tmp-buffer) and paste the
> contents here?
>
>
> ___
> info-gnus-english mailing li