unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Michael Albinus <michael.albinus@gmx.de>
To: Michael Heerdegen <michael_heerdegen@web.de>
Cc: 37489-done@debbugs.gnu.org
Subject: bug#37489: 27.0.50; Make `debbugs-gnu-search' work with `repeat-complex-command'
Date: Tue, 24 Sep 2019 08:51:58 +0200	[thread overview]
Message-ID: <877e5y6vap.fsf@gmx.de> (raw)
In-Reply-To: <87ef064cv1.fsf@web.de> (Michael Heerdegen's message of "Tue, 24 Sep 2019 05:00:50 +0200")

Michael Heerdegen <michael_heerdegen@web.de> writes:

Hi Michael,

>> The appended patch shall do the job, you might test.
>
> Seems to work fine, yes, thanks.

Thanks for testing. There was still an error in the patch; it didn't
distinguish between queries and filters. I have fixed this.

>> However, I fear we will open a Pandora's box. We must set both
>> debbugs-gnu-current-query and debbugs-gnu-current-filter, it depends
>> on whether PHRASE is a string, or not. And even the allowed arguments
>> in both cases are different. So it is very easy to make it wrong when
>> editing the argument list. Even *I* would need to consult the
>> implementation, in order to know what's allowed, and what's
>> not.
>
> I don't find it this problematic.  It's ok when not all combinations of
> arguments are allowed.  But instead of consulting the implementation, it
> would of course be better to describe limitations in the docstring.  If
> it gets too complicated, maybe the list of arguments could be changed to
> reflect the implementation even more.

It's even more complex. There is the difference whether an argument is
appropriate or not, depending on QUERY being a string or nil. But there
is also the difference whether an argument is sent to the server, or
whether the argument's discrimination is done client-side. The latter is
much less performant.

> Anyway, the patch is all that I wanted.  If the command barks the last
> resort is to go through the queries again, which I have to do now
> anyway.
>
>> I would add some further sanity checks for QUERY, before callings
>> debbugs-gnu.
>
> That might be appropriate, but adding some details to the docstring in
> addition along the way might not be wrong, too.  You don't even need to
> explain each argument in detail (maybe you could even point to other
> functions' docstring for that?), just enough to let me know what would
> not work.  FWIW, I never called the command with an empty phrase, since
> I didn't know that this is allowed and even then I would rather expect
> that the server would blacklist me :-)

See the manual, it tells you :-)

`debugs-gnu search' is designed to handle all of this interactively. Now,
that we have arguments, and this command can be called like a function,
I've added a reference to the docstring, pointing to the manual. Plus
the promised sanity checks.

I've pushed the changes to GNU ELPA. I've also released debbugs 0.20,
because the solution for bug#36903, which was blocking the release, is
expected to be applied in gnus.

> Regards,
>
> Michael.

Best regards, Michael.





      reply	other threads:[~2019-09-24  6:51 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-09-23  6:26 bug#37489: 27.0.50; Make `debbugs-gnu-search' work with `repeat-complex-command' Michael Heerdegen
2019-09-23 13:26 ` Michael Albinus
2019-09-24  3:00   ` Michael Heerdegen
2019-09-24  6:51     ` Michael Albinus [this message]

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=877e5y6vap.fsf@gmx.de \
    --to=michael.albinus@gmx.de \
    --cc=37489-done@debbugs.gnu.org \
    --cc=michael_heerdegen@web.de \
    /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).