From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from localhost (localhost [127.0.0.1]) by olra.theworths.org (Postfix) with ESMTP id 89355431FD0 for ; Thu, 4 Jul 2013 00:10:04 -0700 (PDT) X-Virus-Scanned: Debian amavisd-new at olra.theworths.org X-Spam-Flag: NO X-Spam-Score: 0.201 X-Spam-Level: X-Spam-Status: No, score=0.201 tagged_above=-999 required=5 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, FREEMAIL_ENVFROM_END_DIGIT=1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_LOW=-0.7] autolearn=disabled Received: from olra.theworths.org ([127.0.0.1]) by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id gY8Z1DjpBuZZ for ; Thu, 4 Jul 2013 00:09:57 -0700 (PDT) Received: from mail-ea0-f182.google.com (mail-ea0-f182.google.com [209.85.215.182]) (using TLSv1 with cipher RC4-SHA (128/128 bits)) (No client certificate requested) by olra.theworths.org (Postfix) with ESMTPS id C8E15431FBF for ; Thu, 4 Jul 2013 00:09:56 -0700 (PDT) Received: by mail-ea0-f182.google.com with SMTP id d10so557410eaj.41 for ; Thu, 04 Jul 2013 00:09:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id:x-mailer; bh=dXpQCSuZGKGrOz0BYCMjHvHc5g3noH6Bcw9Ft2CCRMA=; b=zfaTVa8EU2HII4ZIbubL91HV6nPHWfDTCdtWMi/LrG7FgcwcWUoQSay63AYXiup7sZ 2vFAcfWY1Xf+c6x1hMRNG17oC6pLh03VU5Hhy3oM8SKg5PJ75G7aBCsEA5d7+L3NPki/ D9pZr0IEMGunun1Ry6BIaVES8f27B9nd3w+2irPlvP8pPmCFdDaC14fUaUkPAO6iftlk LV+jzcS+RVndWwAKJbOw8tobGfgDufFp4EipqXPD4qCTuxq4ji731EP1ocXb3pXFUxSD gQWcX83ZN2WQidizr4mmgNiX9KRtFSx36cVEs0rPYJkfE8pggLEE/EEcWY/mxclZkq38 ryew== X-Received: by 10.14.149.141 with SMTP id x13mr4956634eej.77.1372921792797; Thu, 04 Jul 2013 00:09:52 -0700 (PDT) Received: from localhost (93-97-24-31.zone5.bethere.co.uk. [93.97.24.31]) by mx.google.com with ESMTPSA id p49sm3036046eeu.2.2013.07.04.00.09.51 for (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Thu, 04 Jul 2013 00:09:52 -0700 (PDT) From: Mark Walters To: notmuch@notmuchmail.org Subject: [PATCH] contrib: pick: use notmuch-start-notmuch Date: Thu, 4 Jul 2013 08:09:48 +0100 Message-Id: <1372921788-16042-1-git-send-email-markwalters1009@gmail.com> X-Mailer: git-send-email 1.7.9.1 X-BeenThere: notmuch@notmuchmail.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: "Use and development of the notmuch mail system." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 04 Jul 2013 07:10:04 -0000 This uses the new notmuch-start-notmuch function which should give better handling of stderr and errors generally. --- Hi This converts pick to Austin's new async error handling code (see commit 08fde50bf3a4c54f6413aff4052e0d84392463f9). That code separates stderr from stdout and makes sure that appropriate messages are displayed to the user. I think this is simple enough and beneficial enough to go in for 0.16 (so I will tag it 0.16). Of course it only affects notmuch-pick so is relatively safe. Best wishes Mark contrib/notmuch-pick/notmuch-pick.el | 7 +++---- 1 files changed, 3 insertions(+), 4 deletions(-) diff --git a/contrib/notmuch-pick/notmuch-pick.el b/contrib/notmuch-pick/notmuch-pick.el index fbd7c0b..7f5f729 100644 --- a/contrib/notmuch-pick/notmuch-pick.el +++ b/contrib/notmuch-pick/notmuch-pick.el @@ -817,16 +817,15 @@ Complete list of currently available key bindings: (if (equal (car (process-lines notmuch-command "count" search-args)) "0") (setq search-args basic-query)) (if notmuch-pick-asynchronous-parser - (let ((proc (start-process - "notmuch-pick" buffer - notmuch-command "show" "--body=false" "--format=sexp" + (let ((proc (notmuch-start-notmuch + "notmuch-pick" buffer #'notmuch-pick-process-sentinel + "show" "--body=false" "--format=sexp" message-arg search-args)) ;; Use a scratch buffer to accumulate partial output. ;; This buffer will be killed by the sentinel, which ;; should be called no matter how the process dies. (parse-buf (generate-new-buffer " *notmuch pick parse*"))) (process-put proc 'parse-buf parse-buf) - (set-process-sentinel proc 'notmuch-pick-process-sentinel) (set-process-filter proc 'notmuch-pick-process-filter) (set-process-query-on-exit-flag proc nil)) (progn -- 1.7.9.1