Re: pgarchives: strip angle brackets when checking for msgid search

Поиск
Список
Период
Сортировка
От Amir Rohan
Тема Re: pgarchives: strip angle brackets when checking for msgid search
Дата
Msg-id 56101378.6010006@zoho.com
обсуждение исходный текст
Ответ на Re: pgarchives: strip angle brackets when checking for msgid search  (Magnus Hagander <magnus@hagander.net>)
Ответы Re: pgarchives: strip angle brackets when checking for msgid search
Список pgsql-www
Hi Magnus,

On 10/03/2015 07:31 PM, Magnus Hagander wrote:
> On Fri, Oct 2, 2015 at 7:29 PM, Amir Rohan <amir.rohan@zoho.com
> <mailto:amir.rohan@zoho.com>> wrote:
> 
>     In some email-clients, when you copy the Message-ID to the clipboard
>     it surrounds in (or perhaps, doesn't strip) angle brackets.
>     When pasting this into the mail archive search, search fails to find
>     the message
>     and this happens often enough so as to be annoying. The fix is trivial.
> 
>     Discussion of similar problem in the commitfest app:
> 
>     <CABUevExRGr+Q5gzp-9cDLOqgntsOEcM0zZYg5VkADj3Z_NKz5A@mail.gmail.com>
>     <mailto:CABUevExRGr+Q5gzp-9cDLOqgntsOEcM0zZYg5VkADj3Z_NKz5A@mail.gmail.com>
> 
>     patch attached.
> 
> 
> Interesting - we also had a similar fix in 9b7e9b59 for the archives,
> but that one only deals with the URLs and not the search box. Makes much
> sense to do it in the search box as well, so applied. Thanks! 
> 
> Actually, before I sent this. 
>It's also broken because it redirects to bad URLs if there are spaces
in it.

What is "It"?

> Or if there is just one of the two, > e.g. it has < but not >. 

I'm sorry, I lost you. Let's try and sync...

Prior to this patch:

"msgid" = works
" msgid " = fails
" msgid" = fails
"msgid " = fails
<msgid>" = fails
<msgid" = fails
"msgid>" = fails
" msgid>" = fails
etc'

With this patch -- they should all work.

If there's a search query that currently works and is broken by this
patch, can you give an example?

If you simply mean that searching for "m sgid" is broken, yes it
currently is, and no the patch doesn't fix that.

> All those now generate 404s, which is not good.
> 

"Now" meaning before applying this patch?

> This patch needs to be in sync with the callers of that API as well as
> the code that actually views entries in the archives before it can be
> safely applied.

There is no API change. afaict nothing that currently works and uses
this endpoint should be affected. The only effect should be that
queries that now fail but should succeed, succeed.

I'm happy to address any concerns you have, but I don't understand what
precisely you want done.

Amir





В списке pgsql-www по дате отправления:

Предыдущее
От: Magnus Hagander
Дата:
Сообщение: Re: pgarchives: strip angle brackets when checking for msgid search
Следующее
От: Jeff Janes
Дата:
Сообщение: mailling list archive suggestions