From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Simen =?UTF-8?Q?Heggest=C3=B8yl?= Newsgroups: gmane.emacs.bugs Subject: bug#25236: 26.0.50; sql-postgres not working on master Date: Fri, 30 Dec 2016 19:17:53 +0100 Message-ID: <1483121873.22754.0@smtp.gmail.com> References: <87vauftgz2.fsf@caral.i-did-not-set--mail-host-address--so-tickle-me> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed X-Trace: blaine.gmane.org 1483121956 9487 195.159.176.226 (30 Dec 2016 18:19:16 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Fri, 30 Dec 2016 18:19:16 +0000 (UTC) Cc: 25236@debbugs.gnu.org To: sunshavi@fastmail.fm, Michael Mauger Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Fri Dec 30 19:19:11 2016 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 1cN1ll-0001jG-Hb for geb-bug-gnu-emacs@m.gmane.org; Fri, 30 Dec 2016 19:19:09 +0100 Original-Received: from localhost ([::1]:41052 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cN1lq-00017o-Ce for geb-bug-gnu-emacs@m.gmane.org; Fri, 30 Dec 2016 13:19:14 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:46405) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cN1li-00017e-QJ for bug-gnu-emacs@gnu.org; Fri, 30 Dec 2016 13:19:07 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cN1le-0001kM-Qq for bug-gnu-emacs@gnu.org; Fri, 30 Dec 2016 13:19:06 -0500 Original-Received: from debbugs.gnu.org ([208.118.235.43]:45191) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1cN1le-0001kI-Lm for bug-gnu-emacs@gnu.org; Fri, 30 Dec 2016 13:19:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1cN1le-0006kB-GE for bug-gnu-emacs@gnu.org; Fri, 30 Dec 2016 13:19:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Simen =?UTF-8?Q?Heggest=C3=B8yl?= Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 30 Dec 2016 18:19:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 25236 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 25236-submit@debbugs.gnu.org id=B25236.148312188425845 (code B ref 25236); Fri, 30 Dec 2016 18:19:02 +0000 Original-Received: (at 25236) by debbugs.gnu.org; 30 Dec 2016 18:18:04 +0000 Original-Received: from localhost ([127.0.0.1]:60590 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cN1ki-0006in-H9 for submit@debbugs.gnu.org; Fri, 30 Dec 2016 13:18:04 -0500 Original-Received: from mail-lf0-f52.google.com ([209.85.215.52]:34477) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cN1kf-0006hs-VM for 25236@debbugs.gnu.org; Fri, 30 Dec 2016 13:18:02 -0500 Original-Received: by mail-lf0-f52.google.com with SMTP id y21so240533732lfa.1 for <25236@debbugs.gnu.org>; Fri, 30 Dec 2016 10:18:01 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:subject:to:cc:message-id:in-reply-to:references :mime-version; bh=bZiwUiw4lgL9Qac0zm4u/K6GG/zXpslKSyqc/cz0He8=; b=LV4/alIAxuHZKFjEHX93OO0QGw/9RqHaQGClPc5hJAH3PjXDt/9uxXx/YGOJ5ikHJj lEbFm7jbIHdywNHaVQRxtzptbI+exNHc2NNGHVp8Ov7zjfTIwik2/3sCTCRg7JGU+ZGY t7H+X2CdqeiqBFUAqfazpOpthvX6tLFxN1oLB//hlyYHmr75vmmsaKl76TREsi7tSmIL OgfNKElpPnEqiGu6h2UtB4XWPgPHOudkxhu2uklLKbJhpUUs30E4gUNXfCa0XcW0uz0u uZ+jidfkZl0OaRQrfKqVewp/EqW3sZFafAq475P+X7Dn+Ar90fEf5NW8VC+3tCWRF0qW KV6A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:subject:to:cc:message-id:in-reply-to :references:mime-version; bh=bZiwUiw4lgL9Qac0zm4u/K6GG/zXpslKSyqc/cz0He8=; b=Cr7fVjstnxdWVzJF0FUBe5HHWRmXADZ6rC55As4MzgO/T/kp9XMchumcTNny+quNOE WcbQiTxqHPBV1GEKzNDh6r7X7Qf6hdXU9nbmBtmdBocVuqPdHpsdw51eJEZHhX2Ji38c Oj5WyIkuXt8xKa5gsA6wQOt07qWL6DqqeDw9a/s/MXrTLOBv3vSeOAuLaCXNiWy7y1Y1 twEAgErl1OSuHCHPdQwAXFWKh/pM0t6p5WyIXj100cr2NYCcq1nJ4/oiQGLJGivJVT/d yFL2y00XnOSIyK4JwZc865+jOCJkFo+O56CCeqtvwnKYLJV40WYnLgA6rHMAVQ4isgMF T9EA== X-Gm-Message-State: AIkVDXKb/eoCJs91xeinwNeTGpLgP6wJjWcrnKnQuY0DfXT/MhTBwlKaM+MqhS+02h/XIg== X-Received: by 10.25.213.7 with SMTP id m7mr9515689lfg.36.1483121875913; Fri, 30 Dec 2016 10:17:55 -0800 (PST) Original-Received: from [192.168.100.10] (cm-84.210.143.4.getinternet.no. [84.210.143.4]) by smtp.gmail.com with ESMTPSA id f42sm13918505lji.2.2016.12.30.10.17.54 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Fri, 30 Dec 2016 10:17:55 -0800 (PST) In-Reply-To: <87vauftgz2.fsf@caral.i-did-not-set--mail-host-address--so-tickle-me> X-Mailer: geary/0.11.2 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:127586 Archived-At: This bug seems to be caused by a change I made in https://debbugs.gnu.org/cgi/bugreport.cgi?bug=24646, making `sql-postgres` able to complete the database name by looking at the result of `psql -ltX`. psql exits with status code 2 if the connection to the server went bad, for instance if permissions are missing [1]. I think we can fix this by being more lax in `sql-postgres-list-databases`, and just don't provide any completions should the command fail. Then we'd also need to change the value of the `REQUIRE-MATCH` parameter to `completing-read` on line 2966, since requiring a match when there are no completions would make it impossible to continue. What do you think, Michael? -- Simen [1] https://www.postgresql.org/docs/current/static/app-psql.html#AEN98634