From debbugs-submit-bounces@debbugs.gnu.org Mon May 14 01:55:12 2018 Received: (at submit) by debbugs.gnu.org; 14 May 2018 05:55:12 +0000 Received: from localhost ([127.0.0.1]:32991 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fI6S0-0003Zn-GA for submit@debbugs.gnu.org; Mon, 14 May 2018 01:55:12 -0400 Received: from eggs.gnu.org ([208.118.235.92]:54380) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fI6Ry-0003Zb-UH for submit@debbugs.gnu.org; Mon, 14 May 2018 01:55:11 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fI6Rs-0008O3-J8 for submit@debbugs.gnu.org; Mon, 14 May 2018 01:55:05 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50,FREEMAIL_FROM autolearn=disabled version=3.3.2 Received: from lists.gnu.org ([2001:4830:134:3::11]:35967) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1fI6Rs-0008Nq-GO for submit@debbugs.gnu.org; Mon, 14 May 2018 01:55:04 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:45342) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fI6Rq-0000Ua-VW for bug-gnu-emacs@gnu.org; Mon, 14 May 2018 01:55:04 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fI6Rn-0008HM-IN for bug-gnu-emacs@gnu.org; Mon, 14 May 2018 01:55:03 -0400 Received: from smtp-4.orcon.net.nz ([60.234.4.59]:40402) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1fI6Rn-0008Ci-7d for bug-gnu-emacs@gnu.org; Mon, 14 May 2018 01:54:59 -0400 Received: from [10.253.37.70] (port=59052 helo=webmail.orcon.net.nz) by smtp-4.orcon.net.nz with esmtpa (Exim 4.86_2) (envelope-from ) id 1fI6Rg-0002ep-Tm for bug-gnu-emacs@gnu.org; Mon, 14 May 2018 17:54:53 +1200 Received: from wlgwil-nat-office.catalyst.net.nz ([202.78.240.7]) via [10.253.37.253] by webmail.orcon.net.nz with HTTP (HTTP/1.1 POST); Mon, 14 May 2018 17:54:52 +1200 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Date: Mon, 14 May 2018 17:54:52 +1200 From: Phil Sainty To: bug-gnu-emacs@gnu.org Subject: 26.1; sql-interactive-mode buffer naming is broken Message-ID: X-Sender: psainty@orcon.net.nz User-Agent: Orcon Webmail X-GeoIP: -- X-Spam_score: -2.9 X-Spam_score_int: -28 X-Spam_bar: -- X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 2001:4830:134:3::11 X-Spam-Score: -4.3 (----) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -5.3 (-----) Depending on whether/how many C-u prefix arguments I supply to sql-postgres, the resulting buffer name is bad. M-x sql-postgres: "*SQL: *" C-u M-x sql-postgres: "*SQL: ^D*" C-u C-u M-x sql-postgres: "*SQL: ^P*" I've converted them for the bug report, but the ^D and ^P are actual control characters, which I observe are characters 4 and 16 respectively, and therefore are a match for the numeric value of the supplied prefix argument. This is surely not what was intended. In 25.3 the buffer name would be "*SQL*" with no prefix argument, and if if a prefix argument was given I would be prompted for the buffer name, with "*SQL: @*" as the default suggestion. -Phil In GNU Emacs 26.1 (build 1, x86_64-pc-linux-gnu, X toolkit, Xaw scroll bars) of 2018-04-11 built on mts-devtools Windowing system distributor 'The X.Org Foundation', version 11.0.11501000 System Description: Ubuntu 14.04.5 LTS Recent messages: funcall-interactively: End of buffer [3 times] Login...done funcall-interactively: End of buffer Entering debugger... Continuing. custom-initialize-reset: Symbol’s value as variable is void: buffer-name "*SQL: *" kill-region: Buffer is read-only: # Scanning for dabbrevs...done user-error: No dynamic expansion for ‘sql-int’ found Configured using: 'configure --prefix=/usr/local/src/emacs/26.1/usr/local --with-x-toolkit=lucid --without-sound' Configured features: XPM JPEG TIFF GIF PNG RSVG IMAGEMAGICK DBUS GSETTINGS NOTIFY GNUTLS LIBXML2 FREETYPE XFT ZLIB TOOLKIT_SCROLL_BARS LUCID X11 THREADS LCMS2 Important settings: value of $LANG: en_NZ.UTF-8 locale-coding-system: utf-8-unix Major mode: Messages Minor modes in effect: tooltip-mode: t global-eldoc-mode: t electric-indent-mode: t mouse-wheel-mode: t tool-bar-mode: t menu-bar-mode: t file-name-shadow-mode: t global-font-lock-mode: t font-lock-mode: t blink-cursor-mode: t auto-composition-mode: t auto-encryption-mode: t auto-compression-mode: t buffer-read-only: t line-number-mode: t transient-mark-mode: t Load-path shadows: None found. Features: (shadow sort mail-extr dabbrev emacsbug message rmc puny seq dired dired-loaddefs format-spec rfc822 mml mml-sec password-cache epa derived epg epg-config gnus-util rmail rmail-loaddefs mm-decode mm-bodies mm-encode mail-parse rfc2231 mailabbrev gmm-utils mailheader sendmail rfc2047 rfc2045 ietf-drums mm-util mail-prsvr mail-utils help-mode cl-print byte-opt gv bytecomp byte-compile cconv debug sql easymenu view thingatpt comint ansi-color ring cl-loaddefs cl-lib elec-pair time-date mule-util tooltip eldoc electric uniquify ediff-hook vc-hooks lisp-float-type mwheel term/x-win x-win term/common-win x-dnd tool-bar dnd fontset image regexp-opt fringe tabulated-list replace newcomment text-mode elisp-mode lisp-mode prog-mode register page menu-bar rfn-eshadow isearch timer select scroll-bar mouse jit-lock font-lock syntax facemenu font-core term/tty-colors frame cl-generic cham georgian utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao korean japanese eucjp-ms cp51932 hebrew greek romanian slovak czech european ethiopic indian cyrillic chinese composite charscript charprop case-table epa-hook jka-cmpr-hook help simple abbrev obarray minibuffer cl-preloaded nadvice loaddefs button faces cus-face macroexp files text-properties overlay sha1 md5 base64 format env code-pages mule custom widget hashtable-print-readable backquote dbusbind inotify lcms2 dynamic-setting system-font-setting font-render-setting x-toolkit x multi-tty make-network-process emacs) Memory information: ((conses 16 108297 11486) (symbols 48 21234 1) (miscs 40 119 276) (strings 32 31999 1264) (string-bytes 1 893910) (vectors 16 15325) (vector-slots 8 506954 12212) (floats 8 63 171) (intervals 56 329 0) (buffers 992 16) (heap 1024 45845 3308)) From debbugs-submit-bounces@debbugs.gnu.org Fri May 18 05:49:44 2018 Received: (at 31446) by debbugs.gnu.org; 18 May 2018 09:49:44 +0000 Received: from localhost ([127.0.0.1]:39153 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fJc1A-0003Dw-AN for submit@debbugs.gnu.org; Fri, 18 May 2018 05:49:44 -0400 Received: from eggs.gnu.org ([208.118.235.92]:52941) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fJc18-0003Dk-7l for 31446@debbugs.gnu.org; Fri, 18 May 2018 05:49:42 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fJc0z-0004eK-6B for 31446@debbugs.gnu.org; Fri, 18 May 2018 05:49:37 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=disabled version=3.3.2 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:40186) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fJc0z-0004eE-1r; Fri, 18 May 2018 05:49:33 -0400 Received: from [176.228.60.248] (port=4153 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1fJc0x-0001Pj-PA; Fri, 18 May 2018 05:49:32 -0400 Date: Fri, 18 May 2018 12:49:28 +0300 Message-Id: <83d0xti993.fsf@gnu.org> From: Eli Zaretskii To: Phil Sainty In-reply-to: (message from Phil Sainty on Mon, 14 May 2018 17:54:52 +1200) Subject: Re: bug#31446: 26.1; sql-interactive-mode buffer naming is broken References: X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e X-Spam-Score: -5.0 (-----) X-Debbugs-Envelope-To: 31446 Cc: 31446@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Eli Zaretskii Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -6.0 (------) > Date: Mon, 14 May 2018 17:54:52 +1200 > From: Phil Sainty > > Depending on whether/how many C-u prefix arguments I supply to > sql-postgres, the resulting buffer name is bad. > > M-x sql-postgres: "*SQL: *" > C-u M-x sql-postgres: "*SQL: ^D*" > C-u C-u M-x sql-postgres: "*SQL: ^P*" > > I've converted them for the bug report, but the ^D and ^P are actual > control characters, which I observe are characters 4 and 16 > respectively, and therefore are a match for the numeric value of the > supplied prefix argument. This is surely not what was intended. I cannot use SQL here; does the patch below give good results? diff --git a/lisp/progmodes/sql.el b/lisp/progmodes/sql.el index e4db6cc..dd96810 100644 --- a/lisp/progmodes/sql.el +++ b/lisp/progmodes/sql.el @@ -4263,9 +4263,17 @@ sql-product-interactive (funcall (sql-get-product-feature product :sqli-comint-func) product (sql-get-product-feature product :sqli-options) - (if (and new-name (string-prefix-p "SQL" new-name t)) - new-name - (concat "SQL: " new-name)))) + (when new-name + (cond + ((stringp new-name) + (if (string-prefix-p "SQL" new-name t) + new-name + (concat "SQL: " new-name))) + ((eq new-name '(4)) + (sql-rename-buffer new-name) + sql-alternate-buffer-name) + (t + (format "SQL: %s" new-name)))))) ;; Set SQLi mode. (let ((sql-interactive-product product)) From debbugs-submit-bounces@debbugs.gnu.org Fri May 18 08:20:08 2018 Received: (at 31446) by debbugs.gnu.org; 18 May 2018 12:20:08 +0000 Received: from localhost ([127.0.0.1]:39246 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fJeMh-0000b6-TE for submit@debbugs.gnu.org; Fri, 18 May 2018 08:20:08 -0400 Received: from eggs.gnu.org ([208.118.235.92]:55317) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fJeMf-0000aW-S1 for 31446@debbugs.gnu.org; Fri, 18 May 2018 08:20:06 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fJeMX-00012R-G5 for 31446@debbugs.gnu.org; Fri, 18 May 2018 08:20:00 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=disabled version=3.3.2 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:50781) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fJeMX-00012L-CY; Fri, 18 May 2018 08:19:57 -0400 Received: from [176.228.60.248] (port=4257 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1fJeMW-0005aT-DQ; Fri, 18 May 2018 08:19:57 -0400 Date: Fri, 18 May 2018 15:19:54 +0300 Message-Id: <83bmddi2ad.fsf@gnu.org> From: Eli Zaretskii To: psainty@orcon.net.nz In-reply-to: <83d0xti993.fsf@gnu.org> (message from Eli Zaretskii on Fri, 18 May 2018 12:49:28 +0300) Subject: Re: bug#31446: 26.1; sql-interactive-mode buffer naming is broken References: <83d0xti993.fsf@gnu.org> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e X-Spam-Score: -5.0 (-----) X-Debbugs-Envelope-To: 31446 Cc: 31446@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Eli Zaretskii Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -6.0 (------) > Date: Fri, 18 May 2018 12:49:28 +0300 > From: Eli Zaretskii > Cc: 31446@debbugs.gnu.org > > does the patch below give good results? Sorry, that patch left out an important use case. Please try the one below. (Is it correct to use "*SQL*" when no prefix arg is given?) diff --git a/lisp/progmodes/sql.el b/lisp/progmodes/sql.el index e4db6cc..2ced15c 100644 --- a/lisp/progmodes/sql.el +++ b/lisp/progmodes/sql.el @@ -4263,9 +4263,18 @@ sql-product-interactive (funcall (sql-get-product-feature product :sqli-comint-func) product (sql-get-product-feature product :sqli-options) - (if (and new-name (string-prefix-p "SQL" new-name t)) - new-name - (concat "SQL: " new-name)))) + (cond + ((zerop new-name) + "*SQL*") + ((stringp new-name) + (if (string-prefix-p "SQL" new-name t) + new-name + (concat "*SQL: " new-name "*"))) + ((eq new-name '(4)) + (sql-rename-buffer new-name) + sql-alternate-buffer-name) + (t + (format "*SQL: %s*" new-name))))) ;; Set SQLi mode. (let ((sql-interactive-product product)) From debbugs-submit-bounces@debbugs.gnu.org Fri May 18 11:44:45 2018 Received: (at 31446) by debbugs.gnu.org; 18 May 2018 15:44:45 +0000 Received: from localhost ([127.0.0.1]:39961 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fJhYj-0005TX-0T for submit@debbugs.gnu.org; Fri, 18 May 2018 11:44:45 -0400 Received: from out1-smtp.messagingengine.com ([66.111.4.25]:39033) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fJhYf-0005TN-N6 for 31446@debbugs.gnu.org; Fri, 18 May 2018 11:44:43 -0400 Received: from compute1.internal (compute1.nyi.internal [10.202.2.41]) by mailout.nyi.internal (Postfix) with ESMTP id 5A8432243A; Fri, 18 May 2018 11:44:41 -0400 (EDT) Received: from mailfrontend1 ([10.202.2.162]) by compute1.internal (MEProxy); Fri, 18 May 2018 11:44:41 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fastmail.fm; h= cc:content-type:date:from:in-reply-to:message-id:mime-version :references:subject:to:x-me-sender:x-me-sender:x-sasl-enc; s= fm3; bh=8cjXA+1UCdqtvGzPRaP/mrvenqWIHS2Qou+XMU3gUvk=; b=ED+5lJRf vnH5oTVftAGkK0DFq+fcAzG4vVHZ3RQdN0mYplAw2xALx6dxOQCfMdIBLMSNBTdT a2tkAOSObh/u/LhdZI0kQwRwmjqR9GQfwgtxqkVzmkjLVnIiTCOv0rCEWbJ4/pfj Anbgt8sOqyPeIVk9aHu02yZr84xPBTzYpb0EK9csTMKBg3kIkbg9kJQ4ja+id2Gv 4le44OcvFBJoL7LoxgygA7wUZKJhCu6jfUOl2dmFTjUGuJ2JlV/N3+dza2DFFMxF xsNYuCeWhlaVzQ4x3+pPF65nmD+QI3zuep/osbOdVYeo767/yKhD70fZxvVNycK/ cCDNPa81XK/nYg== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-sender :x-me-sender:x-sasl-enc; s=fm2; bh=8cjXA+1UCdqtvGzPRaP/mrvenqWIH S2Qou+XMU3gUvk=; b=ckkWT/XxwFGES8RSzBZHVZH/MvRhOkWJYCUaX8ywsSRvC M/ZlFIn5/R0xiVnh/lShEUBbQ3aw4+MRQUkXCJIZhFVYMKyJs3MiqfFeKx5prUzn UXn4UnYseYu3DXYaSMKX/tfyG15HTggcXEGZEIeynI6EZ11AR0i1WUcmUSrSnptU Sz4rEnfN9b8xdx/pfjFT/rMcrCSmfbSPpeaftx1Veb/FO+AQ+ZSfa/UqwhCyZrlc 1HmfOGvZAoI5EppzpUosAvzBMZABJ1jI8sU3Wb7InKAUjdHsFDWWvhIZCucQAy5W vy68jdVxJzrh3Cl+LvD32wKmkc+34CF0a6xIHY82Q== X-ME-Proxy: X-ME-Proxy: X-ME-Proxy: X-ME-Proxy: X-ME-Proxy: X-ME-Proxy: X-ME-Sender: Received: from fgunbin.playteam.ru (unknown [94.25.218.10]) by mail.messagingengine.com (Postfix) with ESMTPA id 6A9BEE4BF6; Fri, 18 May 2018 11:44:40 -0400 (EDT) From: Filipp Gunbin To: Eli Zaretskii Subject: Re: bug#31446: 26.1; sql-interactive-mode buffer naming is broken In-Reply-To: <83bmddi2ad.fsf@gnu.org> (Eli Zaretskii's message of "Fri, 18 May 2018 15:19:54 +0300") References: <83d0xti993.fsf@gnu.org> <83bmddi2ad.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (darwin) Date: Fri, 18 May 2018 18:44:38 +0300 Message-ID: MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 31446 Cc: psainty@orcon.net.nz, 31446@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) On 18/05/2018 15:19 +0300, Eli Zaretskii wrote: ... > (funcall (sql-get-product-feature product :sqli-comint-func) > product > (sql-get-product-feature product :sqli-options) > - (if (and new-name (string-prefix-p "SQL" new-name t)) > - new-name > - (concat "SQL: " new-name)))) > + (cond > + ((zerop new-name) > + "*SQL*") > + ((stringp new-name) > + (if (string-prefix-p "SQL" new-name t) > + new-name > + (concat "*SQL: " new-name "*"))) > + ((eq new-name '(4)) > + (sql-rename-buffer new-name) > + sql-alternate-buffer-name) > + (t > + (format "*SQL: %s*" new-name))))) ... But `sql-comint' (called from `sql-comint-postgres' and the like) has logic which prepares buffer name (adding those asterisks etc.) In `sql-product-interactive', `new-name', if set to '(4) from prefix, or to some other value from argument, controls this: (if (and (not new-name) buf) (pop-to-buffer buf) So if `new-name' is set, we shouldn't switch to existing buffer. Maybe just pass `new-name' to comint func like this (undoing possible setting of `new-name' to '(4) above), letting it do all the name-choosing work? (funcall (sql-get-product-feature product :sqli-comint-func) product (sql-get-product-feature product :sqli-options) (if (equal '(4) new-name) nil new-name)) Filipp From debbugs-submit-bounces@debbugs.gnu.org Fri May 18 12:04:57 2018 Received: (at 31446) by debbugs.gnu.org; 18 May 2018 16:04:58 +0000 Received: from localhost ([127.0.0.1]:39977 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fJhsF-0005xg-Rz for submit@debbugs.gnu.org; Fri, 18 May 2018 12:04:56 -0400 Received: from eggs.gnu.org ([208.118.235.92]:55696) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fJhsE-0005xU-Ey for 31446@debbugs.gnu.org; Fri, 18 May 2018 12:04:54 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fJhs6-0003YK-OS for 31446@debbugs.gnu.org; Fri, 18 May 2018 12:04:49 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=disabled version=3.3.2 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:55597) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fJhs6-0003YE-KE; Fri, 18 May 2018 12:04:46 -0400 Received: from [176.228.60.248] (port=4773 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1fJhs5-0000Je-21; Fri, 18 May 2018 12:04:46 -0400 Date: Fri, 18 May 2018 19:04:35 +0300 Message-Id: <83603lhrvw.fsf@gnu.org> From: Eli Zaretskii To: Filipp Gunbin In-reply-to: (message from Filipp Gunbin on Fri, 18 May 2018 18:44:38 +0300) Subject: Re: bug#31446: 26.1; sql-interactive-mode buffer naming is broken References: <83d0xti993.fsf@gnu.org> <83bmddi2ad.fsf@gnu.org> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e X-Spam-Score: -5.0 (-----) X-Debbugs-Envelope-To: 31446 Cc: psainty@orcon.net.nz, 31446@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Eli Zaretskii Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -6.0 (------) > From: Filipp Gunbin > Cc: psainty@orcon.net.nz, 31446@debbugs.gnu.org > Date: Fri, 18 May 2018 18:44:38 +0300 > > But `sql-comint' (called from `sql-comint-postgres' and the like) has > logic which prepares buffer name (adding those asterisks etc.) > > In `sql-product-interactive', `new-name', if set to '(4) from prefix, or > to some other value from argument, controls this: > > (if (and (not new-name) buf) > (pop-to-buffer buf) > > So if `new-name' is set, we shouldn't switch to existing buffer. I'm sorry, but I don't understand the issue you are alluding to. The bug I tried to fix was that the buffer got named incorrectly. Is that fixed by the patch? If it isn't, please tell why. If the patch does fix the bug, then the issues you mention are separate problems, because I don't think I changed the logic of which buffer is going to become the current. What am I missing? From debbugs-submit-bounces@debbugs.gnu.org Fri May 18 14:03:06 2018 Received: (at 31446) by debbugs.gnu.org; 18 May 2018 18:03:06 +0000 Received: from localhost ([127.0.0.1]:40071 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fJjic-0000IW-A9 for submit@debbugs.gnu.org; Fri, 18 May 2018 14:03:06 -0400 Received: from out1-smtp.messagingengine.com ([66.111.4.25]:57801) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fJjiZ-0000IN-RS for 31446@debbugs.gnu.org; Fri, 18 May 2018 14:03:04 -0400 Received: from compute1.internal (compute1.nyi.internal [10.202.2.41]) by mailout.nyi.internal (Postfix) with ESMTP id 54181225C6; Fri, 18 May 2018 14:03:03 -0400 (EDT) Received: from mailfrontend1 ([10.202.2.162]) by compute1.internal (MEProxy); Fri, 18 May 2018 14:03:03 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fastmail.fm; h= cc:content-type:date:from:in-reply-to:message-id:mime-version :references:subject:to:x-me-sender:x-me-sender:x-sasl-enc; s= fm3; bh=KO42m46bew3rL5oej9T0AE3bgagFvFmLndVlLlUaiA8=; b=L5blqGbC ZMmebmkuY42Am0e+K5tr8YZ6EckQfRFcg6eQdS2sJLubg0ffk3x+w7Qnc0VLqK1r 3nQth93pI4rlO9yoPzG3m1L8ICeLqJ/AF2cMhnLvAYzyR9dMEGm80h9V5mY4tJEu qUUJkgprWJhnUpVUotMRMbFpC9cII1VIeawsqkUwH5qt7NiRLtJ0wil7L7ybJOI/ Vdbc5X6X/e/DSrv5hAjyhwlHCzrMlrHsfsyrI0x7/6LGjE61XFLbdsX2Ixia/83Q +5rioetbys9ydX3rTn9unN86gJruvu1QzOVEAn7X3SqldSCe14C/1c/w8MZPdKfR i8aW+XoCxoBwog== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-sender :x-me-sender:x-sasl-enc; s=fm2; bh=KO42m46bew3rL5oej9T0AE3bgagFv FmLndVlLlUaiA8=; b=fb6I2xSMxeZnMCjW+/q4sliX3g+7/LUYqdUUTrV+Vot71 oOpJK5GLfVp1WV4v3/c/ONdmiZWXULumURxnjXLxCYUZFAE89MhbKSihtfOh/TA4 +xUN53hSE0qGJUYETnJAWRFLN/J5dk2HpVoGN14Py/ClwFD9x3beB7NBzOCUc4Y+ 2EM0BH0TugS0q9Qj6nHs+JkHzHtZp8jEdZ+7DnBgLjmffI3z96PnfaGh10oCZaXz QPJ6MuSxmBZyaRk3/izw/6qdOEgNF/x+9ckPj2NUft1/GVssLm9gd2wmiDEbF/DS xJCjM9eFEU3a8YXqIRCRgtISJu4QfqwNQj/CbiasA== X-ME-Proxy: X-ME-Proxy: X-ME-Proxy: X-ME-Proxy: X-ME-Proxy: X-ME-Proxy: X-ME-Sender: Received: from fgunbin.playteam.ru (unknown [94.25.218.10]) by mail.messagingengine.com (Postfix) with ESMTPA id 6098CE43C8; Fri, 18 May 2018 14:03:02 -0400 (EDT) From: Filipp Gunbin To: Eli Zaretskii Subject: Re: bug#31446: 26.1; sql-interactive-mode buffer naming is broken In-Reply-To: <83603lhrvw.fsf@gnu.org> (Eli Zaretskii's message of "Fri, 18 May 2018 19:04:35 +0300") References: <83d0xti993.fsf@gnu.org> <83bmddi2ad.fsf@gnu.org> <83603lhrvw.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (darwin) Date: Fri, 18 May 2018 21:03:00 +0300 Message-ID: MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.3 (/) X-Debbugs-Envelope-To: 31446 Cc: psainty@orcon.net.nz, 31446@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) On 18/05/2018 19:04 +0300, Eli Zaretskii wrote: >> From: Filipp Gunbin >> Cc: psainty@orcon.net.nz, 31446@debbugs.gnu.org >> Date: Fri, 18 May 2018 18:44:38 +0300 >> >> But `sql-comint' (called from `sql-comint-postgres' and the like) has >> logic which prepares buffer name (adding those asterisks etc.) >> >> In `sql-product-interactive', `new-name', if set to '(4) from prefix, or >> to some other value from argument, controls this: >> >> (if (and (not new-name) buf) >> (pop-to-buffer buf) >> >> So if `new-name' is set, we shouldn't switch to existing buffer. > > I'm sorry, but I don't understand the issue you are alluding to. The > bug I tried to fix was that the buffer got named incorrectly. Is that > fixed by the patch? If it isn't, please tell why. > > If the patch does fix the bug, then the issues you mention are > separate problems, because I don't think I changed the logic of which > buffer is going to become the current. > > What am I missing? I was trying to say that probably this function should not mess with the buffer name at all. Your patch, while it may have fixed the bug, introduces some logic on setting buffer name - so we could get undesired behaviour change. While a simpler approach would be just to pass `new-name' like I proposed. I'm not the person who filed this bug, but I also suffer from sqli-mode buffers naming problem :-) Sorry if it's actually me who's missing something. Filipp From debbugs-submit-bounces@debbugs.gnu.org Fri May 18 16:24:45 2018 Received: (at 31446) by debbugs.gnu.org; 18 May 2018 20:24:45 +0000 Received: from localhost ([127.0.0.1]:40223 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fJlvh-0005cF-G9 for submit@debbugs.gnu.org; Fri, 18 May 2018 16:24:45 -0400 Received: from eggs.gnu.org ([208.118.235.92]:48817) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fJlvf-0005c1-Fh for 31446@debbugs.gnu.org; Fri, 18 May 2018 16:24:43 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fJlvX-0005NL-66 for 31446@debbugs.gnu.org; Fri, 18 May 2018 16:24:38 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=disabled version=3.3.2 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:60457) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fJlvX-0005NH-2l; Fri, 18 May 2018 16:24:35 -0400 Received: from [176.228.60.248] (port=1071 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1fJlvW-0006nX-C5; Fri, 18 May 2018 16:24:34 -0400 Date: Fri, 18 May 2018 23:24:31 +0300 Message-Id: <8336yoiuf4.fsf@gnu.org> From: Eli Zaretskii To: Filipp Gunbin In-reply-to: (message from Filipp Gunbin on Fri, 18 May 2018 21:03:00 +0300) Subject: Re: bug#31446: 26.1; sql-interactive-mode buffer naming is broken References: <83d0xti993.fsf@gnu.org> <83bmddi2ad.fsf@gnu.org> <83603lhrvw.fsf@gnu.org> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e X-Spam-Score: -5.0 (-----) X-Debbugs-Envelope-To: 31446 Cc: psainty@orcon.net.nz, 31446@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Eli Zaretskii Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -6.0 (------) > From: Filipp Gunbin > Cc: psainty@orcon.net.nz, 31446@debbugs.gnu.org > Date: Fri, 18 May 2018 21:03:00 +0300 > > Your patch, while it may have fixed the bug, introduces some logic on > setting buffer name - so we could get undesired behaviour change. AFAIK, the logic was already there, I just fixed it to behave more reasonably. The original code was (if (and new-name (string-prefix-p "SQL" new-name t)) new-name (concat "SQL: " new-name)))) This is now (cond ((zerop new-name) "*SQL*") ((stringp new-name) (if (string-prefix-p "SQL" new-name t) new-name (concat "*SQL: " new-name "*"))) ((eq new-name '(4)) (sql-rename-buffer new-name) sql-alternate-buffer-name) (t (format "*SQL: %s*" new-name))))) which (a) avoids concatenating a string and a list '(4); (b) avoids calling string-prefix-p with 2nd arg not a string, something that works only by sheer luck; (c) calls sql-rename-buffer to choose the buffer name, because that function implements the logic of naming the buffer, and duplicating that sounds redundant; (d) does something reasonable when new-name is neither a string nor a prefix arg nor nil. And that is the only thing that I changed. From debbugs-submit-bounces@debbugs.gnu.org Sun May 20 18:17:16 2018 Received: (at 31446) by debbugs.gnu.org; 20 May 2018 22:17:16 +0000 Received: from localhost ([127.0.0.1]:42212 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fKWdg-0002h7-24 for submit@debbugs.gnu.org; Sun, 20 May 2018 18:17:16 -0400 Received: from smtp-2.orcon.net.nz ([60.234.4.43]:53978) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fKWde-0002gw-CU for 31446@debbugs.gnu.org; Sun, 20 May 2018 18:17:14 -0400 Received: from [10.253.37.70] (port=54062 helo=webmail.orcon.net.nz) by smtp-2.orcon.net.nz with esmtpa (Exim 4.86_2) (envelope-from ) id 1fKWdY-0001Bg-F5; Mon, 21 May 2018 10:17:08 +1200 Received: from wlgwil-nat-office.catalyst.net.nz ([202.78.240.7]) via [10.253.37.253] by webmail.orcon.net.nz with HTTP (HTTP/1.1 POST); Mon, 21 May 2018 10:17:08 +1200 MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII; format=flowed Content-Transfer-Encoding: 7bit Date: Mon, 21 May 2018 10:17:08 +1200 From: Phil Sainty To: Eli Zaretskii Subject: Re: bug#31446: 26.1; sql-interactive-mode buffer naming is broken In-Reply-To: <831se6hjnh.fsf@gnu.org> References: <83d0xti993.fsf@gnu.org> <83bmddi2ad.fsf@gnu.org> <83603lhrvw.fsf@gnu.org> <8336yoiuf4.fsf@gnu.org> <831se6hjnh.fsf@gnu.org> Message-ID: X-Sender: psainty@orcon.net.nz User-Agent: Orcon Webmail X-GeoIP: -- X-Spam_score: -2.9 X-Spam_score_int: -28 X-Spam_bar: -- X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 31446 Cc: 31446@debbugs.gnu.org, fgunbin@fastmail.fm X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) Hi Eli, Apologies for lack of testing; I was away while the fix was being discussed. I'll need to test more thoroughly later, but I can tell you that the current code isn't working, as the (zerop new-name) condition produces code like (= 0 nil) or (= 0 '(4)) which results in, e.g., (wrong-type-argument number-or-marker-p (4)) From debbugs-submit-bounces@debbugs.gnu.org Sun May 20 19:53:13 2018 Received: (at 31446) by debbugs.gnu.org; 20 May 2018 23:53:13 +0000 Received: from localhost ([127.0.0.1]:42251 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fKY8X-000581-GI for submit@debbugs.gnu.org; Sun, 20 May 2018 19:53:13 -0400 Received: from out1-smtp.messagingengine.com ([66.111.4.25]:49733) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fKY8V-00057s-Ja for 31446@debbugs.gnu.org; Sun, 20 May 2018 19:53:12 -0400 Received: from compute1.internal (compute1.nyi.internal [10.202.2.41]) by mailout.nyi.internal (Postfix) with ESMTP id EBF782237A; Sun, 20 May 2018 19:53:10 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute1.internal (MEProxy); Sun, 20 May 2018 19:53:10 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fastmail.fm; h= cc:content-type:date:from:in-reply-to:message-id:mime-version :references:subject:to:x-me-sender:x-me-sender:x-sasl-enc; s= fm3; bh=1WJgLlXabzZ+peF+uUg1FKZcudExfp+6ne4edHsEKvI=; b=pCATxymG W5WruCPchuvRq4KyorgDcSEoMNRoSt+HsXtkHuM/GaU38vJLqpkXFmEcQvbiJdSk 1ttbxCz1WCZj/kNV35k/nQQQ8o8NgR67DI2YoQnCTGsj9gooSw2JcSBryq6t6gE/ HDs6kWyNHUUFLQ06+1Wk49MXTbMeZWvqi5CUQeABiPUe2BLV33IaISYTRHqsYwTK 83vyjIf6/oyqSTbTxh16Gc49qemNlBqZDC7/szj/jrAvyr50I211riUiPwDCIETF YCmguTqMibKkAasHUmf8Xt4vfHzmQKHNG1wV3HJiNGv+saytFxJyLIiid7OdgfhZ cetuBzOPdUqHjQ== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-sender :x-me-sender:x-sasl-enc; s=fm2; bh=1WJgLlXabzZ+peF+uUg1FKZcudExf p+6ne4edHsEKvI=; b=MDs+B1Kvkx1ndZnIJoYqbcA0ScNSM1+NKVs54L8G0UaBn GAFT81e5q9wZbaaZIUi+VnOnWIvRaAS/Pq06HntmsHArAkRHQMYD7a437dSNI9fD IHMdf/9oYPOyMgW+lLesSPSQewlS666FrAy8WItYMfBz6qzrUAgbwbbkfOivBOI1 A2PlF4ItFaysPL85j1af5/8mE+J1AKzl5mnCrqk60kS+6qyFW6FpahfLguxw1Obz mXMioVPt3Ya7k38cXYPYp49lFONrbB+4Xp/JYHy584BAKm0X3I1AiOQPFOPTrIGZ IVamsKkcKCRZC4x4ryc7zEjrjE3UlwrqJ6AHjbq/Q== X-ME-Proxy: X-ME-Proxy: X-ME-Proxy: X-ME-Proxy: X-ME-Proxy: X-ME-Proxy: X-ME-Sender: Received: from fgunbin.local (unknown [93.185.19.243]) by mail.messagingengine.com (Postfix) with ESMTPA id F31781025C; Sun, 20 May 2018 19:53:09 -0400 (EDT) From: Filipp Gunbin To: Eli Zaretskii Subject: Re: bug#31446: 26.1; sql-interactive-mode buffer naming is broken In-Reply-To: <8336yoiuf4.fsf@gnu.org> (Eli Zaretskii's message of "Fri, 18 May 2018 23:24:31 +0300") References: <83d0xti993.fsf@gnu.org> <83bmddi2ad.fsf@gnu.org> <83603lhrvw.fsf@gnu.org> <8336yoiuf4.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (darwin) Date: Mon, 21 May 2018 02:53:08 +0300 Message-ID: MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.3 (/) X-Debbugs-Envelope-To: 31446 Cc: psainty@orcon.net.nz, 31446@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) On 18/05/2018 23:24 +0300, Eli Zaretskii wrote: >> From: Filipp Gunbin >> Cc: psainty@orcon.net.nz, 31446@debbugs.gnu.org >> Date: Fri, 18 May 2018 21:03:00 +0300 >> >> Your patch, while it may have fixed the bug, introduces some logic on >> setting buffer name - so we could get undesired behaviour change. > > AFAIK, the logic was already there, I just fixed it to behave more > reasonably. > > The original code was > > (if (and new-name (string-prefix-p "SQL" new-name t)) > new-name > (concat "SQL: " new-name)))) > > This is now > (cond > ((zerop new-name) > "*SQL*") > ((stringp new-name) > (if (string-prefix-p "SQL" new-name t) > new-name > (concat "*SQL: " new-name "*"))) > ((eq new-name '(4)) > (sql-rename-buffer new-name) > sql-alternate-buffer-name) > (t > (format "*SQL: %s*" new-name))))) > > which (a) avoids concatenating a string and a list '(4); (b) avoids > calling string-prefix-p with 2nd arg not a string, something that > works only by sheer luck; (c) calls sql-rename-buffer to choose the > buffer name, because that function implements the logic of naming the > buffer, and duplicating that sounds redundant; (d) does something > reasonable when new-name is neither a string nor a prefix arg nor nil. > > And that is the only thing that I changed. That looks reasonable, but, as I wrote earlier, why implement name-choosing logic here, if it's in `sql-comint' already. Even if some of such logic was here before the fix, it doesn't necessarily mean that was right. > ((eq new-name '(4)) > (sql-rename-buffer new-name) > sql-alternate-buffer-name) `sql-alternate-buffer-name' not always matches the effective name set by `sql-rename-buffer'.. I'll test my suggestion tomorrow and will write about the result, if you don't mind. Filipp From debbugs-submit-bounces@debbugs.gnu.org Sun May 20 22:35:25 2018 Received: (at 31446) by debbugs.gnu.org; 21 May 2018 02:35:25 +0000 Received: from localhost ([127.0.0.1]:42328 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fKafV-00050m-DJ for submit@debbugs.gnu.org; Sun, 20 May 2018 22:35:25 -0400 Received: from eggs.gnu.org ([208.118.235.92]:60476) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fKafU-00050Y-Kj for 31446@debbugs.gnu.org; Sun, 20 May 2018 22:35:24 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fKafM-0002U1-5a for 31446@debbugs.gnu.org; Sun, 20 May 2018 22:35:19 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=disabled version=3.3.2 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:41185) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fKafM-0002Tv-3G; Sun, 20 May 2018 22:35:16 -0400 Received: from [176.228.60.248] (port=2282 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1fKafL-0000Ac-Fd; Sun, 20 May 2018 22:35:15 -0400 Date: Mon, 21 May 2018 05:35:17 +0300 Message-Id: <83h8n1g2hm.fsf@gnu.org> From: Eli Zaretskii To: Phil Sainty In-reply-to: (message from Phil Sainty on Mon, 21 May 2018 10:17:08 +1200) Subject: Re: bug#31446: 26.1; sql-interactive-mode buffer naming is broken References: <83d0xti993.fsf@gnu.org> <83bmddi2ad.fsf@gnu.org> <83603lhrvw.fsf@gnu.org> <8336yoiuf4.fsf@gnu.org> <831se6hjnh.fsf@gnu.org> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e X-Spam-Score: -5.0 (-----) X-Debbugs-Envelope-To: 31446 Cc: 31446@debbugs.gnu.org, fgunbin@fastmail.fm X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Eli Zaretskii Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -6.0 (------) > Date: Mon, 21 May 2018 10:17:08 +1200 > From: Phil Sainty > Cc: fgunbin@fastmail.fm, 31446@debbugs.gnu.org > > I'll need to test more thoroughly later, but I can tell you > that the current code isn't working, as the (zerop new-name) > condition produces code like (= 0 nil) or (= 0 '(4)) which > results in, e.g., (wrong-type-argument number-or-marker-p (4)) Sorry, that was a stupid typo, now fixed. From debbugs-submit-bounces@debbugs.gnu.org Mon May 21 08:09:43 2018 Received: (at 31446) by debbugs.gnu.org; 21 May 2018 12:09:43 +0000 Received: from localhost ([127.0.0.1]:42569 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fKjdF-0005mg-9B for submit@debbugs.gnu.org; Mon, 21 May 2018 08:09:42 -0400 Received: from smtp-2.orcon.net.nz ([60.234.4.43]:35083) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fKjdD-0005mY-M6 for 31446@debbugs.gnu.org; Mon, 21 May 2018 08:09:40 -0400 Received: from [10.253.37.70] (port=56525 helo=webmail.orcon.net.nz) by smtp-2.orcon.net.nz with esmtpa (Exim 4.86_2) (envelope-from ) id 1fKjdA-0003B4-BI; Tue, 22 May 2018 00:09:37 +1200 Received: from [150.107.175.250] via [10.253.37.253] by webmail.orcon.net.nz with HTTP (HTTP/1.1 POST); Tue, 22 May 2018 00:09:36 +1200 MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII; format=flowed Content-Transfer-Encoding: 7bit Date: Tue, 22 May 2018 00:09:36 +1200 From: Phil Sainty To: Eli Zaretskii Subject: Re: bug#31446: 26.1; sql-interactive-mode buffer naming is broken In-Reply-To: <83h8n1g2hm.fsf@gnu.org> References: <83d0xti993.fsf@gnu.org> <83bmddi2ad.fsf@gnu.org> <83603lhrvw.fsf@gnu.org> <8336yoiuf4.fsf@gnu.org> <831se6hjnh.fsf@gnu.org> <83h8n1g2hm.fsf@gnu.org> Message-ID: <42fe26038dde2b56636888cfbf4e37bb@webmail.orcon.net.nz> X-Sender: psainty@orcon.net.nz User-Agent: Orcon Webmail X-GeoIP: -- X-Spam_score: -2.9 X-Spam_score_int: -28 X-Spam_bar: -- X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 31446 Cc: 31446@debbugs.gnu.org, fgunbin@fastmail.fm, bug-gnu-emacs , "Michael R. Mauger" X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) On 2018-05-21 14:35, Eli Zaretskii wrote: > Sorry, that was a stupid typo, now fixed. No error now, but there's still a bug. (eq new-name '(4)) is never true, so it falls through to (format "*SQL: %s*" new-name) when a prefix arg is supplied. I *think* we'd want (consp new-name) for that test (especially as it ought to cover multiple uses of C-u), *however* doing this then triggers error "Current buffer is not a SQL interactive buffer" in `sql-rename-buffer', as this is happening *before* the call to the :sqli-comint-func function which creates the buffer. I've briefly tested Filipp's suggestion, but that seemed to result in just *SQL* as a buffer name regardless of the prefix argument, rather than causing it to prompt for the name (however that might turn out to be sane in conjunction with the additional changes I've made below?) The following is working from initial/cursory testing, but it needs more testing/confirmation at minimum. diff --git a/lisp/progmodes/sql.el b/lisp/progmodes/sql.el index 1b2cdaf5f6..45ce9154b0 100644 --- a/lisp/progmodes/sql.el +++ b/lisp/progmodes/sql.el @@ -4264,14 +4264,13 @@ sql-product-interactive product (sql-get-product-feature product :sqli-options) (cond - ((null new-name) + ((or (null new-name) + (consp new-name)) "*SQL*") ((stringp new-name) (if (string-prefix-p "*SQL: " new-name t) new-name (concat "*SQL: " new-name "*"))) - ((eq new-name '(4)) - (sql-rename-buffer new-name)) (t (format "*SQL: %s*" new-name))))) @@ -4279,6 +4278,10 @@ sql-product-interactive (let ((sql-interactive-product product)) (sql-interactive-mode)) + ;; Prompt for the buffer name if a prefix argument was given. + (when (consp new-name) + (sql-rename-buffer new-name)) + ;; Set the new buffer name (setq new-sqli-buffer (current-buffer)) (set (make-local-variable 'sql-buffer) Setting just "*SQL*" initially in the case of (consp new-name) is to prevent the comint process name from ending up as, e.g., "SQL: (4)", which is particularly noticeable when exiting the process, to the message: "Process SQL: (4) finished" Comparing with Emacs 25.3, this would simply say "Process SQL finished", and using "*SQL*" in the new code appears to give this result. This bug could probably use some attention from whoever made the changes to how this was in Emacs 25, which I think was this commit: commit c5a31f8292c94d19b80a3dbe0b3026693cc1090e Author: Michael R. Mauger Date: Mon Mar 20 23:26:53 2017 -0400 Ccing Michael -- See https://debbugs.gnu.org/cgi/bugreport.cgi?bug=31446 -Phil From debbugs-submit-bounces@debbugs.gnu.org Mon May 21 10:55:50 2018 Received: (at 31446) by debbugs.gnu.org; 21 May 2018 14:55:51 +0000 Received: from localhost ([127.0.0.1]:43130 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fKmE2-00019l-LD for submit@debbugs.gnu.org; Mon, 21 May 2018 10:55:50 -0400 Received: from eggs.gnu.org ([208.118.235.92]:34663) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fKmDx-00019V-H6 for 31446@debbugs.gnu.org; Mon, 21 May 2018 10:55:46 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fKmDo-0002Vj-Jh for 31446@debbugs.gnu.org; Mon, 21 May 2018 10:55:40 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=disabled version=3.3.2 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:53653) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fKmDo-0002VT-CI; Mon, 21 May 2018 10:55:36 -0400 Received: from [176.228.60.248] (port=2891 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1fKmDn-0007iZ-Sd; Mon, 21 May 2018 10:55:36 -0400 Date: Mon, 21 May 2018 17:55:40 +0300 Message-Id: <83d0xpf47n.fsf@gnu.org> From: Eli Zaretskii To: Filipp Gunbin In-reply-to: (message from Filipp Gunbin on Mon, 21 May 2018 02:53:08 +0300) Subject: Re: bug#31446: 26.1; sql-interactive-mode buffer naming is broken References: <83d0xti993.fsf@gnu.org> <83bmddi2ad.fsf@gnu.org> <83603lhrvw.fsf@gnu.org> <8336yoiuf4.fsf@gnu.org> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e X-Spam-Score: -5.0 (-----) X-Debbugs-Envelope-To: 31446 Cc: psainty@orcon.net.nz, 31446@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Eli Zaretskii Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -6.0 (------) > From: Filipp Gunbin > Cc: psainty@orcon.net.nz, 31446@debbugs.gnu.org > Date: Mon, 21 May 2018 02:53:08 +0300 > > That looks reasonable, but, as I wrote earlier, why implement > name-choosing logic here, if it's in `sql-comint' already. Even if some > of such logic was here before the fix, it doesn't necessarily mean that > was right. Maybe I'm missing something, but it looks like sql-comint and sql-product-interactive belong to 2 different families of entry points in the package. Some call sql-product-interactive, while the others call sql-comint. Isn't that so? From debbugs-submit-bounces@debbugs.gnu.org Mon May 21 11:45:59 2018 Received: (at 31446) by debbugs.gnu.org; 21 May 2018 15:45:59 +0000 Received: from localhost ([127.0.0.1]:43162 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fKn0X-0002I4-ST for submit@debbugs.gnu.org; Mon, 21 May 2018 11:45:59 -0400 Received: from eggs.gnu.org ([208.118.235.92]:45523) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fKn0W-0002Hs-Ip for 31446@debbugs.gnu.org; Mon, 21 May 2018 11:45:56 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fKn0Q-0001cO-HK for 31446@debbugs.gnu.org; Mon, 21 May 2018 11:45:51 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=disabled version=3.3.2 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:54345) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fKn0G-0001YM-5m; Mon, 21 May 2018 11:45:40 -0400 Received: from [176.228.60.248] (port=2945 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1fKn0F-0006QC-K4; Mon, 21 May 2018 11:45:40 -0400 Date: Mon, 21 May 2018 18:45:42 +0300 Message-Id: <83603hf1w9.fsf@gnu.org> From: Eli Zaretskii To: Phil Sainty In-reply-to: <42fe26038dde2b56636888cfbf4e37bb@webmail.orcon.net.nz> (message from Phil Sainty on Tue, 22 May 2018 00:09:36 +1200) Subject: Re: bug#31446: 26.1; sql-interactive-mode buffer naming is broken References: <83d0xti993.fsf@gnu.org> <83bmddi2ad.fsf@gnu.org> <83603lhrvw.fsf@gnu.org> <8336yoiuf4.fsf@gnu.org> <831se6hjnh.fsf@gnu.org> <83h8n1g2hm.fsf@gnu.org> <42fe26038dde2b56636888cfbf4e37bb@webmail.orcon.net.nz> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e X-Spam-Score: -5.0 (-----) X-Debbugs-Envelope-To: 31446 Cc: 31446@debbugs.gnu.org, fgunbin@fastmail.fm, bug-gnu-emacs-bounces+psainty=orcon.net.nz@gnu.org, michael@mauger.com X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Eli Zaretskii Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -6.0 (------) > Date: Tue, 22 May 2018 00:09:36 +1200 > From: Phil Sainty > Cc: 31446@debbugs.gnu.org, fgunbin@fastmail.fm, bug-gnu-emacs > , "Michael R. Mauger" > > > (eq new-name '(4)) is never true, so it falls through to > (format "*SQL: %s*" new-name) when a prefix arg is supplied. Right, thanks. > I *think* we'd want (consp new-name) for that test (especially as > it ought to cover multiple uses of C-u), *however* doing this then > triggers error "Current buffer is not a SQL interactive buffer" in > `sql-rename-buffer', as this is happening *before* the call to the > :sqli-comint-func function which creates the buffer. Right, so we need to pull the relevant stuff out of that function. > I've briefly tested Filipp's suggestion, but that seemed to result in > just *SQL* as a buffer name regardless of the prefix argument, rather > than causing it to prompt for the name (however that might turn out to > be sane in conjunction with the additional changes I've made below?) > > The following is working from initial/cursory testing, but it needs > more testing/confirmation at minimum. Thanks, I tried fixing it in a slightly different way, please take a look. I'd like to avoid releasing Emacs 26.1 with sql.el that was broken by latest changes. From debbugs-submit-bounces@debbugs.gnu.org Mon May 21 18:08:10 2018 Received: (at 31446) by debbugs.gnu.org; 21 May 2018 22:08:11 +0000 Received: from localhost ([127.0.0.1]:43323 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fKsyQ-0004Qp-Mm for submit@debbugs.gnu.org; Mon, 21 May 2018 18:08:10 -0400 Received: from smtp-2.orcon.net.nz ([60.234.4.43]:56142) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fKsyO-0004Qh-OJ for 31446@debbugs.gnu.org; Mon, 21 May 2018 18:08:09 -0400 Received: from [10.253.37.70] (port=38495 helo=webmail.orcon.net.nz) by smtp-2.orcon.net.nz with esmtpa (Exim 4.86_2) (envelope-from ) id 1fKsyL-0001fB-MM; Tue, 22 May 2018 10:08:05 +1200 Received: from wlgwil-nat-office.catalyst.net.nz ([202.78.240.7]) via [10.253.37.253] by webmail.orcon.net.nz with HTTP (HTTP/1.1 POST); Tue, 22 May 2018 10:08:05 +1200 MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII; format=flowed Content-Transfer-Encoding: 7bit Date: Tue, 22 May 2018 10:08:05 +1200 From: Phil Sainty To: Eli Zaretskii Subject: Re: bug#31446: 26.1; sql-interactive-mode buffer naming is broken In-Reply-To: <83603hf1w9.fsf@gnu.org> References: <83d0xti993.fsf@gnu.org> <83bmddi2ad.fsf@gnu.org> <83603lhrvw.fsf@gnu.org> <8336yoiuf4.fsf@gnu.org> <831se6hjnh.fsf@gnu.org> <83h8n1g2hm.fsf@gnu.org> <42fe26038dde2b56636888cfbf4e37bb@webmail.orcon.net.nz> <83603hf1w9.fsf@gnu.org> Message-ID: <51c17257ab43917d561cc5e56a556d67@webmail.orcon.net.nz> X-Sender: psainty@orcon.net.nz User-Agent: Orcon Webmail X-GeoIP: -- X-Spam_score: -2.9 X-Spam_score_int: -28 X-Spam_bar: -- X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 31446 Cc: 31446@debbugs.gnu.org, fgunbin@fastmail.fm, bug-gnu-emacs-bounces+psainty=orcon.net.nz@gnu.org, michael@mauger.com X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) On 2018-05-22 03:45, Eli Zaretskii wrote: > Thanks, I tried fixing it in a slightly different way, please take a > look. I'd like to avoid releasing Emacs 26.1 with sql.el that was > broken by latest changes. That seems to work, except for regressing this bit: >> I *think* we'd want (consp new-name) for that test (especially as >> it ought to cover multiple uses of C-u) With C-u C-u M-x sql-postgres I end up with buffer name "*SQL: (16)*" and "Process SQL: (16) finished" etc. Another difference from Emacs 25 is that using a prefix arg in Emacs 25 was guaranteed to create a new buffer/process (if the chosen buffer name conflicted then it was uniquified), whereas the new code is switching to the pre-existing buffer in the situation. Calling `sql-rename-buffer' handles uniquification, and my suggested code seems to be consistent with the old behaviour. Hopefully Filipp (or others) can do some testing as well -- I've not been as thorough as I would like, so it would be good to have others verifying the changes too. -Phil As a side-note, I've just observed that killing SQLi buffers from the `list-buffers' buffer triggers "error in process sentinel: Selecting deleted buffer" after confirming that the process should be killed (which prevents marking and killing *multiple* such buffers). I see this also happens in Emacs 25, however. From debbugs-submit-bounces@debbugs.gnu.org Mon May 21 22:38:07 2018 Received: (at 31446) by debbugs.gnu.org; 22 May 2018 02:38:07 +0000 Received: from localhost ([127.0.0.1]:43411 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fKxBe-00027T-Vn for submit@debbugs.gnu.org; Mon, 21 May 2018 22:38:07 -0400 Received: from eggs.gnu.org ([208.118.235.92]:41259) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fKxBd-000271-LO for 31446@debbugs.gnu.org; Mon, 21 May 2018 22:38:05 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fKxBV-0008Ff-Fl for 31446@debbugs.gnu.org; Mon, 21 May 2018 22:38:00 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-0.5 required=5.0 tests=BAYES_05 autolearn=disabled version=3.3.2 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:37249) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fKxBM-0008DM-0w; Mon, 21 May 2018 22:37:48 -0400 Received: from [176.228.60.248] (port=3693 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1fKxBL-0000v5-F5; Mon, 21 May 2018 22:37:47 -0400 Date: Tue, 22 May 2018 05:37:50 +0300 Message-Id: <83muwse7pd.fsf@gnu.org> From: Eli Zaretskii To: Phil Sainty In-reply-to: <51c17257ab43917d561cc5e56a556d67@webmail.orcon.net.nz> (message from Phil Sainty on Tue, 22 May 2018 10:08:05 +1200) Subject: Re: bug#31446: 26.1; sql-interactive-mode buffer naming is broken References: <83d0xti993.fsf@gnu.org> <83bmddi2ad.fsf@gnu.org> <83603lhrvw.fsf@gnu.org> <8336yoiuf4.fsf@gnu.org> <831se6hjnh.fsf@gnu.org> <83h8n1g2hm.fsf@gnu.org> <42fe26038dde2b56636888cfbf4e37bb@webmail.orcon.net.nz> <83603hf1w9.fsf@gnu.org> <51c17257ab43917d561cc5e56a556d67@webmail.orcon.net.nz> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e X-Spam-Score: -5.0 (-----) X-Debbugs-Envelope-To: 31446 Cc: 31446@debbugs.gnu.org, fgunbin@fastmail.fm, bug-gnu-emacs-bounces+psainty=orcon.net.nz@gnu.org, michael@mauger.com X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Eli Zaretskii Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -6.0 (------) > Date: Tue, 22 May 2018 10:08:05 +1200 > From: Phil Sainty > Cc: 31446@debbugs.gnu.org, fgunbin@fastmail.fm, > bug-gnu-emacs-bounces+psainty=orcon.net.nz@gnu.org, michael@mauger.com > > On 2018-05-22 03:45, Eli Zaretskii wrote: > > Thanks, I tried fixing it in a slightly different way, please take a > > look. I'd like to avoid releasing Emacs 26.1 with sql.el that was > > broken by latest changes. > > That seems to work, except for regressing this bit: > > >> I *think* we'd want (consp new-name) for that test (especially as > >> it ought to cover multiple uses of C-u) > > With C-u C-u M-x sql-postgres I end up with buffer name "*SQL: (16)*" > and "Process SQL: (16) finished" etc. What is "C-u C-u" sup[posed to achieve? It isn't called out in the doc strings, AFAICS, is it? > Another difference from Emacs 25 is that using a prefix arg in Emacs 25 > was guaranteed to create a new buffer/process (if the chosen buffer name > conflicted then it was uniquified), whereas the new code is switching to > the pre-existing buffer in the situation. This will have to be dealt with after Emacs 26.1 release. Thanks. From debbugs-submit-bounces@debbugs.gnu.org Tue May 22 00:01:19 2018 Received: (at 31446) by debbugs.gnu.org; 22 May 2018 04:01:19 +0000 Received: from localhost ([127.0.0.1]:43448 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fKyUB-00040J-Ap for submit@debbugs.gnu.org; Tue, 22 May 2018 00:01:19 -0400 Received: from smtp-2.orcon.net.nz ([60.234.4.43]:57084) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fKyU9-00040A-B7 for 31446@debbugs.gnu.org; Tue, 22 May 2018 00:01:17 -0400 Received: from [10.253.37.70] (port=43615 helo=webmail.orcon.net.nz) by smtp-2.orcon.net.nz with esmtpa (Exim 4.86_2) (envelope-from ) id 1fKyU6-0007is-01; Tue, 22 May 2018 16:01:14 +1200 Received: from wlgwil-nat-office.catalyst.net.nz ([202.78.240.7]) via [10.253.37.253] by webmail.orcon.net.nz with HTTP (HTTP/1.1 POST); Tue, 22 May 2018 16:01:13 +1200 MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII; format=flowed Content-Transfer-Encoding: 7bit Date: Tue, 22 May 2018 16:01:13 +1200 From: Phil Sainty To: Eli Zaretskii Subject: Re: bug#31446: 26.1; sql-interactive-mode buffer naming is broken In-Reply-To: <83muwse7pd.fsf@gnu.org> References: <83d0xti993.fsf@gnu.org> <83bmddi2ad.fsf@gnu.org> <83603lhrvw.fsf@gnu.org> <8336yoiuf4.fsf@gnu.org> <831se6hjnh.fsf@gnu.org> <83h8n1g2hm.fsf@gnu.org> <42fe26038dde2b56636888cfbf4e37bb@webmail.orcon.net.nz> <83603hf1w9.fsf@gnu.org> <51c17257ab43917d561cc5e56a556d67@webmail.orcon.net.nz> <83muwse7pd.fsf@gnu.org> Message-ID: X-Sender: psainty@orcon.net.nz User-Agent: Orcon Webmail X-GeoIP: -- X-Spam_score: -2.9 X-Spam_score_int: -28 X-Spam_bar: -- X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 31446 Cc: 31446@debbugs.gnu.org, fgunbin@fastmail.fm, bug-gnu-emacs-bounces+psainty=orcon.net.nz@gnu.org, michael@mauger.com X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) On 2018-05-22 14:37, Eli Zaretskii wrote: > What is "C-u C-u" supposed to achieve? It isn't called out in the > doc strings, AFAICS, is it? Well that's an excellent question. `sql-product-interactive' does support C-u C-u, but I realise now that that `product' is its prefix arg and in the case of C-u C-u it sets a value of '(4) for `new-name'; so you're right -- there's no particular need to support other values. Personally I would still be inclined to use `consp' just so that additional C-u presses didn't result in the odd names that you currently get, but that's obviously not a major concern. >> Another difference from Emacs 25 is that using a prefix arg in Emacs >> 25 >> was guaranteed to create a new buffer/process (if the chosen buffer >> name >> conflicted then it was uniquified), whereas the new code is switching >> to >> the pre-existing buffer in the situation. > > This will have to be dealt with after Emacs 26.1 release. Ok. -Phil From debbugs-submit-bounces@debbugs.gnu.org Tue May 22 07:27:36 2018 Received: (at 31446) by debbugs.gnu.org; 22 May 2018 11:27:36 +0000 Received: from localhost ([127.0.0.1]:43741 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fL5S4-000638-6o for submit@debbugs.gnu.org; Tue, 22 May 2018 07:27:36 -0400 Received: from out1-smtp.messagingengine.com ([66.111.4.25]:50819) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fL5S1-00062z-R9 for 31446@debbugs.gnu.org; Tue, 22 May 2018 07:27:34 -0400 Received: from compute1.internal (compute1.nyi.internal [10.202.2.41]) by mailout.nyi.internal (Postfix) with ESMTP id A359421127; Tue, 22 May 2018 07:27:33 -0400 (EDT) Received: from mailfrontend1 ([10.202.2.162]) by compute1.internal (MEProxy); Tue, 22 May 2018 07:27:33 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fastmail.fm; h= cc:content-type:date:from:in-reply-to:message-id:mime-version :references:subject:to:x-me-sender:x-me-sender:x-sasl-enc; s= fm3; bh=dOqUp1lQG4X88hpI0qsAHfBh4qNKZyw4suz/FuJsu4E=; b=fpv/dsjQ nxH4NupRgRTaeX+nJUTSkf4jf9dstF9I95rI3XK9fTd/XTuvPlALR93lWnPTVTFy oqO/CDebBNYlEZp84LA/gvJ5pHP/7zAfKBLWnrI592hNdSGnIpx6sWb0tcR3zSiI YhRqgrBMMuYUHas0lYAmEpiBP9kGxuEGjs2yMk3PLCBohpZaFTxoAaZgsgxVwn85 2bFinvWzkoBCYSs5dDGZDaA1OkAt0qs6BHsmFStBdn2S6pQlE0iRnX+S/eIpYjqH /28Sr5M+RPYfXkmM1NhojWA+S96IOO+V5ezC1fLDirxw/0K571x4tLBzbd3hzhwj zzrtSO0iaH1f+Q== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-sender :x-me-sender:x-sasl-enc; s=fm2; bh=dOqUp1lQG4X88hpI0qsAHfBh4qNKZ yw4suz/FuJsu4E=; b=DYV4utXGOix/y4wtMHxv0A0aT5ZhdvLbLZqIuw81hZyvZ DUKoXTGhqn+Bt7gva4iCG2kmzIeiUNljJKf18s5JQi1yUulOirJpGfk36k3g0oHn dqtshQ7fv0XaBC7Z4mN2nXRpB2tKlVNOeIIj9k6oSUJEBi+tyDnJN+2ToIOScHMg 3SZ8PxTGJgOWXLq9sd8apcnw5hHQu6lKlsMyG6Zs4kFj8RTbpHbXGZr+H46naVnn OCASJ4fej4KYxHOqAHQ+LIa+ZOwl9hh9cC5LkHs6IEU3wCK2CZsN/ei6IZKzhPnT FMw5MVFBXXNko5HWcaITqrtEiaRVJ8QAPiakL5bdA== X-ME-Proxy: X-ME-Proxy: X-ME-Proxy: X-ME-Proxy: X-ME-Proxy: X-ME-Proxy: X-ME-Sender: Received: from fgunbin.local (dhcp4.pdmi.ras.ru [83.149.197.228]) by mail.messagingengine.com (Postfix) with ESMTPA id 9D297E490E; Tue, 22 May 2018 07:27:32 -0400 (EDT) From: Filipp Gunbin To: Eli Zaretskii Subject: Re: bug#31446: 26.1; sql-interactive-mode buffer naming is broken In-Reply-To: <83d0xpf47n.fsf@gnu.org> (Eli Zaretskii's message of "Mon, 21 May 2018 17:55:40 +0300") References: <83d0xti993.fsf@gnu.org> <83bmddi2ad.fsf@gnu.org> <83603lhrvw.fsf@gnu.org> <8336yoiuf4.fsf@gnu.org> <83d0xpf47n.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (darwin) Date: Tue, 22 May 2018 14:27:27 +0300 Message-ID: MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.3 (/) X-Debbugs-Envelope-To: 31446 Cc: psainty@orcon.net.nz, 31446@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) On 21/05/2018 17:55 +0300, Eli Zaretskii wrote: >> From: Filipp Gunbin >> Cc: psainty@orcon.net.nz, 31446@debbugs.gnu.org >> Date: Mon, 21 May 2018 02:53:08 +0300 >> >> That looks reasonable, but, as I wrote earlier, why implement >> name-choosing logic here, if it's in `sql-comint' already. Even if some >> of such logic was here before the fix, it doesn't necessarily mean that >> was right. > > Maybe I'm missing something, but it looks like sql-comint and > sql-product-interactive belong to 2 different families of entry points > in the package. Some call sql-product-interactive, while the others > call sql-comint. Isn't that so? sql-product-interactive is one of the entry points (a generic one). Other entry points are sql-postgres and the like, which specify product. Well, this patch works for me. If I call `C-u C-u sql-product-interactive' multiple times, then first I get *SQL* buffer, then *SQL-postgres* buffer, then *SQL-postgres1* and so on. With just C-u I am switched to existing buffer. Filipp diff --git a/lisp/progmodes/sql.el b/lisp/progmodes/sql.el index 64651aff11..856250c194 100644 --- a/lisp/progmodes/sql.el +++ b/lisp/progmodes/sql.el @@ -4196,10 +4196,8 @@ sql-product-interactive If buffer `*SQL*' exists but no process is running, make a new process. If buffer exists and a process is running, just switch to buffer `*SQL*'. -To specify the SQL product, prefix the call with -\\[universal-argument]. To set the buffer name as well, prefix -the call to \\[sql-product-interactive] with -\\[universal-argument] \\[universal-argument]. +When called interactively, \\[universal-argument] enables product selection. +\\[universal-argument] \\[universal-argument], in addition to that, forces new buffer to be created. \(Type \\[describe-mode] in the SQL buffer for a list of commands.)" (interactive "P") @@ -4254,9 +4252,7 @@ sql-product-interactive (funcall (sql-get-product-feature product :sqli-comint-func) product (sql-get-product-feature product :sqli-options) - (if (and new-name (string-prefix-p "SQL" new-name t)) - new-name - (concat "SQL: " new-name)))) + (if (consp new-name) nil new-name))) ;; Set SQLi mode. (let ((sql-interactive-product product)) From debbugs-submit-bounces@debbugs.gnu.org Tue May 22 12:42:42 2018 Received: (at 31446) by debbugs.gnu.org; 22 May 2018 16:42:42 +0000 Received: from localhost ([127.0.0.1]:44359 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fLAMz-00077D-PD for submit@debbugs.gnu.org; Tue, 22 May 2018 12:42:41 -0400 Received: from eggs.gnu.org ([208.118.235.92]:60515) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fLAMy-000771-Ns for 31446@debbugs.gnu.org; Tue, 22 May 2018 12:42:40 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fLAMq-0004cp-L0 for 31446@debbugs.gnu.org; Tue, 22 May 2018 12:42:35 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-0.5 required=5.0 tests=BAYES_05 autolearn=disabled version=3.3.2 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:49713) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fLAMq-0004cl-Gd; Tue, 22 May 2018 12:42:32 -0400 Received: from [176.228.60.248] (port=4358 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1fLAMp-00070h-UC; Tue, 22 May 2018 12:42:32 -0400 Date: Tue, 22 May 2018 19:42:38 +0300 Message-Id: <83fu2jej5t.fsf@gnu.org> From: Eli Zaretskii To: Filipp Gunbin , Michael Mauger In-reply-to: (message from Filipp Gunbin on Tue, 22 May 2018 14:27:27 +0300) Subject: Re: bug#31446: 26.1; sql-interactive-mode buffer naming is broken References: <83d0xti993.fsf@gnu.org> <83bmddi2ad.fsf@gnu.org> <83603lhrvw.fsf@gnu.org> <8336yoiuf4.fsf@gnu.org> <83d0xpf47n.fsf@gnu.org> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e X-Spam-Score: -5.0 (-----) X-Debbugs-Envelope-To: 31446 Cc: psainty@orcon.net.nz, 31446@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Eli Zaretskii Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -6.0 (------) > From: Filipp Gunbin > Cc: psainty@orcon.net.nz, 31446@debbugs.gnu.org > Date: Tue, 22 May 2018 14:27:27 +0300 > > > Maybe I'm missing something, but it looks like sql-comint and > > sql-product-interactive belong to 2 different families of entry points > > in the package. Some call sql-product-interactive, while the others > > call sql-comint. Isn't that so? > > sql-product-interactive is one of the entry points (a generic one). > Other entry points are sql-postgres and the like, which specify product. I said "families" of entry points. I could be missing something, but it looked to me that interactive sql.el commands that call sql-comint don't call sql-product-interactive, and vice versa. If I'm right, this problem cannot be solved by using sql-comint. > Well, this patch works for me. Thanks, I hope Micheal (CC'ed) will look into this when he has time. From debbugs-submit-bounces@debbugs.gnu.org Tue May 22 15:15:49 2018 Received: (at 31446) by debbugs.gnu.org; 22 May 2018 19:15:49 +0000 Received: from localhost ([127.0.0.1]:44458 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fLClB-00029s-67 for submit@debbugs.gnu.org; Tue, 22 May 2018 15:15:49 -0400 Received: from out3-smtp.messagingengine.com ([66.111.4.27]:36541) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fLCl8-00029k-Hl for 31446@debbugs.gnu.org; Tue, 22 May 2018 15:15:47 -0400 Received: from compute1.internal (compute1.nyi.internal [10.202.2.41]) by mailout.nyi.internal (Postfix) with ESMTP id 6510721356; Tue, 22 May 2018 15:15:46 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute1.internal (MEProxy); Tue, 22 May 2018 15:15:46 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fastmail.fm; h= cc:content-type:date:from:in-reply-to:message-id:mime-version :references:subject:to:x-me-sender:x-me-sender:x-sasl-enc; s= fm3; bh=ainASqdovw6GzJ7QtJeZ9isH+eA6yfPoAvcVUxAJ8fc=; b=dALIU3m9 JBGSxI332KulSyrPYk73xKm+jfsatgEUWbPq+YJpD9PxyrpRDHc4ZfmM4gRgtr6A v8SzfSHxw6QDgakUaSxZRYcDZ9zrXlmtX2MjrRPSE0fH8oIf1Zvca/vJz55JNKnu zEmRXEBmOlRzzL9AjgXhUhglSiNHh4SeqY6RJzv2nSyInEGbg0XbU97EX84eZfAn yvrwOFPw4g+u9pS5xf/FdD06G1r9Iaw699UhvIGWqOIHu6psWh2L4yk0ZXAbd5dZ EHCzlqBcSi/1Tnnu3j2kKVXWuRRqdXZ8hYH5FIh7Ewn+FPNdI21B+MDsETcanfLX r9eZwyXnOk9tOw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-sender :x-me-sender:x-sasl-enc; s=fm2; bh=ainASqdovw6GzJ7QtJeZ9isH+eA6y fPoAvcVUxAJ8fc=; b=I9c6V0D142dx6t1f7MW4s6Ko55W1akaiNLEiVHhRY59by 9vZpQhpmQ3IkVSyG3sL67ypqYLGeXgLq9sjSHky3NBRZ5Dpyb8yx8lLulaMEgGMx cKcnK9mDn8xXooa6D7HYJTNt74idvrQLheOpDJ5gOePL21Q9c/UXu2Absj7neDUR /qAMEbAV9vHmZuyhqDvp/ijG8yAeQcx88bgIxzAevwLbzO/eK5hFUaydkmJTh606 3tKkmdNBpqH72jo53arclP3Y70mW0hQGFerwiEogS1YNIwrCkTvi2uANw488qc20 58McPI2Uw6Ch/iLKtWBOfJX8+ukKhmHP/AvapNAaA== X-ME-Proxy: X-ME-Proxy: X-ME-Proxy: X-ME-Proxy: X-ME-Proxy: X-ME-Proxy: X-ME-Sender: Received: from fgunbin.playteam.ru (unknown [94.25.218.10]) by mail.messagingengine.com (Postfix) with ESMTPA id 4CAC810262; Tue, 22 May 2018 15:15:45 -0400 (EDT) From: Filipp Gunbin To: Eli Zaretskii Subject: Re: bug#31446: 26.1; sql-interactive-mode buffer naming is broken In-Reply-To: <83fu2jej5t.fsf@gnu.org> (Eli Zaretskii's message of "Tue, 22 May 2018 19:42:38 +0300") References: <83d0xti993.fsf@gnu.org> <83bmddi2ad.fsf@gnu.org> <83603lhrvw.fsf@gnu.org> <8336yoiuf4.fsf@gnu.org> <83d0xpf47n.fsf@gnu.org> <83fu2jej5t.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (darwin) Date: Tue, 22 May 2018 22:15:43 +0300 Message-ID: MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.3 (/) X-Debbugs-Envelope-To: 31446 Cc: psainty@orcon.net.nz, Michael Mauger , 31446@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) On 22/05/2018 19:42 +0300, Eli Zaretskii wrote: >> From: Filipp Gunbin >> Cc: psainty@orcon.net.nz, 31446@debbugs.gnu.org >> Date: Tue, 22 May 2018 14:27:27 +0300 >> >> > Maybe I'm missing something, but it looks like sql-comint and >> > sql-product-interactive belong to 2 different families of entry points >> > in the package. Some call sql-product-interactive, while the others >> > call sql-comint. Isn't that so? >> >> sql-product-interactive is one of the entry points (a generic one). >> Other entry points are sql-postgres and the like, which specify product. > > I said "families" of entry points. I could be missing something, but > it looked to me that interactive sql.el commands that call sql-comint > don't call sql-product-interactive, and vice versa. If I'm right, > this problem cannot be solved by using sql-comint. Here's a quote from sql.el: ;; sql-interactive-mode is used to interact with a SQL interpreter ;; process in a SQLi buffer (usually called `*SQL*'). The SQLi buffer ;; is created by calling a SQL interpreter-specific entry function or ;; sql-product-interactive. Do *not* call sql-interactive-mode by ;; itself. That's what I wrote about previously. If there are some other ways of entering interactive sql mode, then I'm not aware of them, sorry. First entry point, sql-product-interactive, calls specific comint function, say sql-comint-postgres. These product-specific functions call sql-comint. Second entry point(s), sql-postgres and the like, just call sql-product-interactive. So it all boils down to sql-comint in the end. Sorry if I'm wrong somewhere. >> Well, this patch works for me. > > Thanks, I hope Micheal (CC'ed) will look into this when he has time. Yes, thanks. Filipp From debbugs-submit-bounces@debbugs.gnu.org Wed May 23 09:48:28 2018 Received: (at 31446) by debbugs.gnu.org; 23 May 2018 13:48:28 +0000 Received: from localhost ([127.0.0.1]:44909 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fLU7w-0000Xd-08 for submit@debbugs.gnu.org; Wed, 23 May 2018 09:48:28 -0400 Received: from mail1.protonmail.ch ([185.70.40.18]:64853) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fLU7r-0000XR-AP for 31446@debbugs.gnu.org; Wed, 23 May 2018 09:48:23 -0400 Date: Wed, 23 May 2018 09:48:07 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=protonmail.com; s=default; t=1527083292; bh=sdIeJEiHDUtO/PTVB6twtMES87b31RSBazJctwKVm3g=; h=Date:To:From:Cc:Reply-To:Subject:In-Reply-To:References: Feedback-ID:From; b=IDJ1w+WL5E78+gaLq6/zo2HNk4iIxzgZSv/qPmQ7yPf2AikrNS0h6QEDeMoFxRFzG L/b8AO2e/OfdYoLLJFQ5JPg314Lq0V2MKXV6a4Tp6mzxKtZweXjY/EcYSGHf4MYfhi eW+hzSwseqpGME0qd5HNpjxkEaELcpiK2Gn1Xrk4= To: Filipp Gunbin From: Michael Mauger Subject: Re: bug#31446: 26.1; sql-interactive-mode buffer naming is broken Message-ID: In-Reply-To: References: <83603lhrvw.fsf@gnu.org> <8336yoiuf4.fsf@gnu.org> <83d0xpf47n.fsf@gnu.org> <83fu2jej5t.fsf@gnu.org> Feedback-ID: b6CpL0MxcIA6fpHRkn3ZHzWS0Hoqxbtv_SrHfEzC9D85cLvnRsVk4rKaAOJUw48iy20W0W1VX4whjBYFluIX0w==:Ext:ProtonMail MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-1.1 required=5.0 tests=ALL_TRUSTED,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM autolearn=ham autolearn_force=no version=3.4.1 X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on mail.protonmail.ch X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 31446 Cc: "psainty@orcon.net.nz" , Michael Mauger , Eli Zaretskii , "31446@debbugs.gnu.org" <31446@debbugs.gnu.org> X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Michael Mauger Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) =E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90 Original Me= ssage =E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90 On May 22, 2018 3:15 PM, Filipp Gunbin wrote: > >=20 > > Thanks, I hope Micheal (CC'ed) will look into this when he has time. >=20 > Yes, thanks. >=20 > Filipp There is some confusion here and I will take a look. I won't get to it unti= l this weekend however. The original package had buffer naming scattered in several places. I've tr= ied to consolidate it. It works much better for my workflow but there are o= bviously still some problems. =E2=80=8B-- MICHAEL@MAUGER.COM // FSF and EFF member // GNU Emacs sql.el maintainer= =E2=80=8B From debbugs-submit-bounces@debbugs.gnu.org Tue May 29 03:52:37 2018 Received: (at 31446) by debbugs.gnu.org; 29 May 2018 07:52:37 +0000 Received: from localhost ([127.0.0.1]:53073 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fNZQq-0007tg-VW for submit@debbugs.gnu.org; Tue, 29 May 2018 03:52:37 -0400 Received: from out1-smtp.messagingengine.com ([66.111.4.25]:50615) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fNZQq-0007tZ-4E for 31446@debbugs.gnu.org; Tue, 29 May 2018 03:52:36 -0400 Received: from compute1.internal (compute1.nyi.internal [10.202.2.41]) by mailout.nyi.internal (Postfix) with ESMTP id AA24B21B4D; Tue, 29 May 2018 03:52:35 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute1.internal (MEProxy); Tue, 29 May 2018 03:52:35 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fastmail.fm; h= cc:content-type:date:from:in-reply-to:message-id:mime-version :references:subject:to:x-me-sender:x-me-sender:x-sasl-enc; s= fm3; bh=iYm/L+C2sLsyytpzDCCOf/R27JYcsYR0yA3hrT5xZLI=; b=kBLO6XHf R2DcsXh1PhjcXdbcmRd+atofHdFtWpvbegOAoPcHgqcBAokhEDnTlqoDHTQbk1oY 1qamaVAJ/58j5/arVrjKUYAtmnIBiew1Py+/Qc19MjkigjOJAYZnbBEC/p+DuF4o sMlnVjS1Ni7xVGgKYFT5VisFWPpdVS/AfeCyQfFm5fh78YKbkjzgk9gu0ElMLrJD hPTvloN9KA07Lh2gYlkzeuFDxpVbqGKNTPCV9ek6215IGIS+pfk4ffddB041YxtN AbHRK7rpB39SyllEGq1oqWTnYOXw9uXxQY1MWNSdxYtLVX0VY3eO5VY71xpzyX0G r2joZGvmrd7j4A== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-sender :x-me-sender:x-sasl-enc; s=fm2; bh=iYm/L+C2sLsyytpzDCCOf/R27JYcs YR0yA3hrT5xZLI=; b=SlwHHqt/EN4wBOtWExQ0n04UkmlD9FWFqUX8lRJflUuVG 7FxeZx3rzeFSsYOaUkSgthppRZ8uO7wD7HydL0iWkm9/d3rHDPzOEBFDx6Oz53EZ DhBQn9yRbVxbvr0Wo11MXfpnez5tK2F7vxhXN9d7HpwO5nVibzb3+BnedWJfbn/R UzTNYvpXAu2N+R0KZxnTUX+UyCZtYPxEJ5mbjV4fSYLPtFCoItvRqADXmnvtNBKZ 6VA9lLoaQN70qfYkIC5AvUYtChIvEnCLaOsGHSVG39JhP2jPgAejVefKNfKX4SWZ 9oy2Tp0v3wBtxZeHHYpHjjQ1e/8T/RV5Ad0D7wIRQ== X-ME-Proxy: X-ME-Proxy: X-ME-Proxy: X-ME-Proxy: X-ME-Proxy: X-ME-Proxy: X-ME-Sender: Received: from fgunbin.local (unknown [93.185.26.108]) by mail.messagingengine.com (Postfix) with ESMTPA id 93508102DA; Tue, 29 May 2018 03:52:34 -0400 (EDT) From: Filipp Gunbin To: Michael Mauger Subject: Re: bug#31446: 26.1; sql-interactive-mode buffer naming is broken In-Reply-To: (Michael Mauger's message of "Wed, 23 May 2018 09:48:07 -0400") References: <83603lhrvw.fsf@gnu.org> <8336yoiuf4.fsf@gnu.org> <83d0xpf47n.fsf@gnu.org> <83fu2jej5t.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (darwin) Date: Tue, 29 May 2018 10:52:32 +0300 Message-ID: MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 31446 Cc: "psainty@orcon.net.nz" , "31446@debbugs.gnu.org" <31446@debbugs.gnu.org>, Eli Zaretskii X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) On 23/05/2018 09:48 -0400, Michael Mauger wrote: > There is some confusion here and I will take a look. I won't get to it > until this weekend however. Michael, ping? Thanks. From debbugs-submit-bounces@debbugs.gnu.org Tue May 29 10:36:34 2018 Received: (at 31446) by debbugs.gnu.org; 29 May 2018 14:36:34 +0000 Received: from localhost ([127.0.0.1]:54135 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fNfjm-0006p3-13 for submit@debbugs.gnu.org; Tue, 29 May 2018 10:36:34 -0400 Received: from mail2.protonmail.ch ([185.70.40.22]:18717) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fNfjk-0006ou-4t for 31446@debbugs.gnu.org; Tue, 29 May 2018 10:36:32 -0400 Date: Tue, 29 May 2018 10:36:13 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=protonmail.com; s=default; t=1527604580; bh=Z4JRHozS9akTvJTG3/BJPYTRLWlUro6UeoFhV5UUkIE=; h=Date:To:From:Cc:Reply-To:Subject:In-Reply-To:References: Feedback-ID:From; b=Ernt3numsXm2WW3RnqH6WuiGPmonaziNdQbX50qqW/+HkB6/XBjHyh7nUPvVZR6wl ZD/qMLM3wI9WgGarH0ztxq6csTHdBafdtR+YyXZBSW6HURlyqugKEzIZgUCwm6uI7w f/StitPTsyyHsbLJIysgSPl0w/bnEtBreCw4oZi8= To: Filipp Gunbin From: Michael Mauger Subject: Re: bug#31446: 26.1; sql-interactive-mode buffer naming is broken Message-ID: In-Reply-To: References: <8336yoiuf4.fsf@gnu.org> <83d0xpf47n.fsf@gnu.org> <83fu2jej5t.fsf@gnu.org> Feedback-ID: b6CpL0MxcIA6fpHRkn3ZHzWS0Hoqxbtv_SrHfEzC9D85cLvnRsVk4rKaAOJUw48iy20W0W1VX4whjBYFluIX0w==:Ext:ProtonMail MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-1.1 required=5.0 tests=ALL_TRUSTED,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM autolearn=ham autolearn_force=no version=3.4.1 X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on mail.protonmail.ch X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 31446 Cc: "psainty\\@orcon.net.nz" , "31446\\@debbugs.gnu.org" <31446@debbugs.gnu.org>, Eli Zaretskii X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Michael Mauger Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) =E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90 Original Me= ssage =E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90 On May 29, 2018 3:52 AM, Filipp Gunbin wrote: > =E2=80=8B=E2=80=8B >=20 > On 23/05/2018 09:48 -0400, Michael Mauger wrote: >=20 > > There is some confusion here and I will take a look. I won't get to it > >=20 > > until this weekend however. >=20 > Michael, ping? >=20 > Thanks. Sorry, got home late last nite from the long weekend (US Memorial Day). I = was away but spent several hours researching this over the weekend and tryi= ng to figure out how to address it. I was confused because I had addressed this bug months ago. My work journal= indicates that I had committed a significant reworking of the buffer namin= g code last Fall. However, it appears that I messed up with git and the com= mit never made it to savannah. I was using a copy of the changes on an olde= r distribution I use in the office where I interact with databases daily.= =20 I realize that 26.1 has been released, so my changes obviously won't make i= t. I have a version of the package with vastly improved and consistent buff= er naming but I want to now test it more heavily. My plan is to update the = DOCSTRINGs, update the NEWS file, and add to the test suite so that behavio= r is better defined and consistent. Longer-term, I want to introduce a Info= document to describe configuration and workflows related to SQL developmen= t. I am very sorry that I messed this up and hadn't properly followed-up to ma= ke sure things were stable. I have been battling with my employer over my c= ontributions which are not done on their time. Despite their interference, = I am refocusing my energy on the sql.el code and making sure that its quali= ty meets the high standards of the rest of Emacs. =E2=80=8B--=20 MICHAEL@MAUGER.COM // FSF and EFF member // GNU Emacs sql.el maintainer= =E2=80=8B From debbugs-submit-bounces@debbugs.gnu.org Tue May 29 12:49:34 2018 Received: (at 31446) by debbugs.gnu.org; 29 May 2018 16:49:34 +0000 Received: from localhost ([127.0.0.1]:54242 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fNhoU-0001Wg-CH for submit@debbugs.gnu.org; Tue, 29 May 2018 12:49:34 -0400 Received: from eggs.gnu.org ([208.118.235.92]:58800) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fNhoT-0001WV-Gc for 31446@debbugs.gnu.org; Tue, 29 May 2018 12:49:33 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fNhoK-0008U6-4L for 31446@debbugs.gnu.org; Tue, 29 May 2018 12:49:28 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-0.0 required=5.0 tests=BAYES_20 autolearn=disabled version=3.3.2 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:36141) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fNhoK-0008U2-1P; Tue, 29 May 2018 12:49:24 -0400 Received: from [176.228.60.248] (port=1415 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1fNhoJ-0000ad-F2; Tue, 29 May 2018 12:49:23 -0400 Date: Tue, 29 May 2018 19:49:18 +0300 Message-Id: <83po1ev241.fsf@gnu.org> From: Eli Zaretskii To: Michael Mauger In-reply-to: (message from Michael Mauger on Tue, 29 May 2018 10:36:13 -0400) Subject: Re: bug#31446: 26.1; sql-interactive-mode buffer naming is broken References: <8336yoiuf4.fsf@gnu.org> <83d0xpf47n.fsf@gnu.org> <83fu2jej5t.fsf@gnu.org> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e X-Spam-Score: -5.0 (-----) X-Debbugs-Envelope-To: 31446 Cc: psainty@orcon.net.nz, 31446@debbugs.gnu.org, fgunbin@fastmail.fm X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Eli Zaretskii Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -6.0 (------) > Date: Tue, 29 May 2018 10:36:13 -0400 > From: Michael Mauger > Cc: Eli Zaretskii , "psainty\\@orcon.net.nz" , "31446\\@debbugs.gnu.org" <31446@debbugs.gnu.org> > > I realize that 26.1 has been released, so my changes obviously won't make it. We could put them in Emacs 26.2, if the changes are relatively safe bugfixes. Thanks. From debbugs-submit-bounces@debbugs.gnu.org Tue May 29 15:48:07 2018 Received: (at 31446) by debbugs.gnu.org; 29 May 2018 19:48:07 +0000 Received: from localhost ([127.0.0.1]:54351 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fNkbH-0007hF-9U for submit@debbugs.gnu.org; Tue, 29 May 2018 15:48:07 -0400 Received: from out1-smtp.messagingengine.com ([66.111.4.25]:42811) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fNkbE-0007h6-NE for 31446@debbugs.gnu.org; Tue, 29 May 2018 15:48:05 -0400 Received: from compute1.internal (compute1.nyi.internal [10.202.2.41]) by mailout.nyi.internal (Postfix) with ESMTP id 41FF221BEA; Tue, 29 May 2018 15:48:04 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute1.internal (MEProxy); Tue, 29 May 2018 15:48:04 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fastmail.fm; h= cc:content-type:date:from:in-reply-to:message-id:mime-version :references:subject:to:x-me-sender:x-me-sender:x-sasl-enc; s= fm3; bh=fjuCI5s4LMcgBpkHIqIFKiYDV6OaLvwGzRIW+2bxXjo=; b=YIoQygsN iaF8KH7RX53cslp+M8dEUlr60ApWVAsKORQOsCx4P+OAZDkSL8aKGYPek25NH4Rm nSK0JLI+V0gjgw1NKiOMccij4L3XnumpjkURq3Al/6CFo7iJXsg6FWhXQNhAAAUN SxqRHnBbnoBvxZJDwLWWDvqqlY05YSBQ5UgnAZodnA0S/orSsakJ0JPL9DecGbqC r4AAoaKuAEQz91HxEGHclT/ZO1etnOXJxWv0i4l87ofmVPlVGzA7sLFFyPwgVIT+ pq7/+H68tEawJmOaw3aonwA/OQ001feQcFCNzUFVpHhGKJZC52PDNS2/VcVdkZgR MVVjnMppa6dFDw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-sender :x-me-sender:x-sasl-enc; s=fm2; bh=fjuCI5s4LMcgBpkHIqIFKiYDV6OaL vwGzRIW+2bxXjo=; b=JIDzWz7xgoDAvEaqhcj23YvvO12wFJfTyJfpMEhMsZLuD w1ytBDZkbBRZu604XIrwKyTbjWliQz5ubZ5CXmLKLq8Ie3iqF5gYxYqeVW3SKb58 +U5vuknTvdWZqcsJzSi0b/cak5RhOsGA8TFjt1rdy1jombVDqK7m5Y3Jvs7W8GaR 1laQPRV1lFn4voRURwKzveJx0eUEjBId6usccZO/pOPesYDpz7358tCgS2DLqOyv 5lGM8oWYTbvvESJ6iSl9sKN6I8T9vFKXnBGqHFZEDemd1KTLgmZaWy02AzaBERya rmUIw8bWVi7DZbyyzG5zThyKGWbM/uOyLu3WAFmpA== X-ME-Proxy: X-ME-Proxy: X-ME-Proxy: X-ME-Proxy: X-ME-Proxy: X-ME-Proxy: X-ME-Sender: Received: from fgunbin.playteam.ru (unknown [94.25.218.10]) by mail.messagingengine.com (Postfix) with ESMTPA id 24E9C1025E; Tue, 29 May 2018 15:48:03 -0400 (EDT) From: Filipp Gunbin To: Michael Mauger Subject: Re: bug#31446: 26.1; sql-interactive-mode buffer naming is broken In-Reply-To: (Michael Mauger's message of "Tue, 29 May 2018 10:36:13 -0400") References: <8336yoiuf4.fsf@gnu.org> <83d0xpf47n.fsf@gnu.org> <83fu2jej5t.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (darwin) Date: Tue, 29 May 2018 22:48:00 +0300 Message-ID: MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 31446 Cc: "psainty@orcon.net.nz" , "31446@debbugs.gnu.org" <31446@debbugs.gnu.org>, Eli Zaretskii X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) On 29/05/2018 10:36 -0400, Michael Mauger wrote: > I realize that 26.1 has been released, so my changes obviously won't > make it. I have a version of the package with vastly improved and > consistent buffer naming but I want to now test it more heavily. My > plan is to update the DOCSTRINGs, update the NEWS file, and add to the > test suite so that behavior is better defined and > consistent. Longer-term, I want to introduce a Info document to > describe configuration and workflows related to SQL development. I was just confused a bit about the latest changes. While they may have fixed the original bug (and got into 26.1), I find them strange in that they AFAICT duplicate (in incomplete way) what is done in sql-comint. May I ask you to look at past messages in this thread and clarify the matters, if you have some time? Currently we're talking about few lines of changes. If it all looks bad to you, then we just forget this until your improved version. Filipp From debbugs-submit-bounces@debbugs.gnu.org Tue May 29 19:32:12 2018 Received: (at 31446) by debbugs.gnu.org; 29 May 2018 23:32:12 +0000 Received: from localhost ([127.0.0.1]:54430 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fNo68-0001wl-Ba for submit@debbugs.gnu.org; Tue, 29 May 2018 19:32:12 -0400 Received: from smtp-1.orcon.net.nz ([60.234.4.34]:37740) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fNo65-0001wb-Kn for 31446@debbugs.gnu.org; Tue, 29 May 2018 19:32:11 -0400 Received: from [10.253.37.70] (port=46980 helo=webmail.orcon.net.nz) by smtp-1.orcon.net.nz with esmtpa (Exim 4.86_2) (envelope-from ) id 1fNo5x-000284-SP; Wed, 30 May 2018 11:32:01 +1200 Received: from wlgwil-nat-office.catalyst.net.nz ([202.78.240.7]) via [10.253.37.253] by webmail.orcon.net.nz with HTTP (HTTP/1.1 POST); Wed, 30 May 2018 11:32:01 +1200 MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII; format=flowed Content-Transfer-Encoding: 7bit Date: Wed, 30 May 2018 11:32:01 +1200 From: Phil Sainty To: Michael Mauger Subject: Re: bug#31446: 26.1; sql-interactive-mode buffer naming is broken In-Reply-To: References: <8336yoiuf4.fsf@gnu.org> <83d0xpf47n.fsf@gnu.org> <83fu2jej5t.fsf@gnu.org> Message-ID: X-Sender: psainty@orcon.net.nz User-Agent: Orcon Webmail X-GeoIP: -- X-Spam_score: -2.9 X-Spam_score_int: -28 X-Spam_bar: -- X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 31446 Cc: 31446@debbugs.gnu.org, Filipp Gunbin , bug-gnu-emacs X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) On 2018-05-30 02:36, Michael Mauger wrote: > I realize that 26.1 has been released, so my changes obviously won't > make it. I have a version of the package with vastly improved and > consistent buffer naming but I want to now test it more heavily. If it's in a state where some help with testing would be useful, perhaps you could push the new code to a separate branch? (My own availability is rather patchy for the next 2-3 weeks, but I should be able to give it a decent whirl over the next few days, and maybe others can too?) cheers, -Phil From debbugs-submit-bounces@debbugs.gnu.org Tue May 29 22:52:06 2018 Received: (at 31446) by debbugs.gnu.org; 30 May 2018 02:52:06 +0000 Received: from localhost ([127.0.0.1]:54521 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fNrDa-0006nn-Br for submit@debbugs.gnu.org; Tue, 29 May 2018 22:52:06 -0400 Received: from mail2.protonmail.ch ([185.70.40.22]:19195) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fNrDY-0006nd-4o for 31446@debbugs.gnu.org; Tue, 29 May 2018 22:52:04 -0400 Date: Tue, 29 May 2018 22:51:35 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=protonmail.com; s=default; t=1527648707; bh=nQh5DSB4Tug9fVzm6gUcpvbEbboo7n4pR/Z16ao82lY=; h=Date:To:From:Cc:Reply-To:Subject:In-Reply-To:References: Feedback-ID:From; b=aUTqoEHTI+L3EWSeuLhGBTx7Z3BEJL9Snp0OgUzvoGj/3D5m/1+ntFH1Lwehrf8+K fyx1Z6r/41E38euFHsbKrRQVhsor6CwMfeNbzd2F1tKpiK2S3L4ioRIB44Ftn1Wpl/ MTSIN/8EXF8xuBeSa5z22UkQzqssQt57xofj/Lgw= To: Phil Sainty From: Michael Mauger Subject: Re: bug#31446: 26.1; sql-interactive-mode buffer naming is broken Message-ID: In-Reply-To: References: <83d0xpf47n.fsf@gnu.org> <83fu2jej5t.fsf@gnu.org> Feedback-ID: b6CpL0MxcIA6fpHRkn3ZHzWS0Hoqxbtv_SrHfEzC9D85cLvnRsVk4rKaAOJUw48iy20W0W1VX4whjBYFluIX0w==:Ext:ProtonMail MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-1.1 required=5.0 tests=ALL_TRUSTED,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM autolearn=ham autolearn_force=no version=3.4.1 X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on mail.protonmail.ch X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 31446 Cc: "31446@debbugs.gnu.org" <31446@debbugs.gnu.org>, Filipp Gunbin , bug-gnu-emacs X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Michael Mauger Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) =E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90 Original Me= ssage =E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90 On May 29, 2018 7:32 PM, Phil Sainty wrote: >=20 > On 2018-05-30 02:36, Michael Mauger wrote: >=20 > > I realize that 26.1 has been released, so my changes obviously won't > > make it. I have a version of the package with vastly improved and > > consistent buffer naming but I want to now test it more heavily. >=20 > If it's in a state where some help with testing would be useful, > perhaps you could push the new code to a separate branch? (My own > availability is rather patchy for the next 2-3 weeks, but I should be > able to give it a decent whirl over the next few days, and maybe > others can too?) I expect to make an initial commit to master in a couple of days of sql.el.= =20 That will be followed up with a commit of improved DOCSTRINGs, tests, and possibly an Info file. I'll leave it to Eli et al. to decide whether the sql.el on master gets mer= ged=20 into the emacs-26 branch later. =E2=80=8B-- MICHAEL@MAUGER.COM // FSF and EFF member // GNU Emacs sql.el maintainer= =E2=80=8B From debbugs-submit-bounces@debbugs.gnu.org Wed May 30 12:43:31 2018 Received: (at 31446) by debbugs.gnu.org; 30 May 2018 16:43:31 +0000 Received: from localhost ([127.0.0.1]:55352 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fO4CB-0005WQ-A2 for submit@debbugs.gnu.org; Wed, 30 May 2018 12:43:31 -0400 Received: from eggs.gnu.org ([208.118.235.92]:51752) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fO4C9-0005WD-Cv for 31446@debbugs.gnu.org; Wed, 30 May 2018 12:43:29 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fO4C3-0005g6-D6 for 31446@debbugs.gnu.org; Wed, 30 May 2018 12:43:24 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=disabled version=3.3.2 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:59328) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fO4Bx-0005cN-J7; Wed, 30 May 2018 12:43:17 -0400 Received: from [176.228.60.248] (port=1210 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1fO4Bw-0000EY-Ug; Wed, 30 May 2018 12:43:17 -0400 Date: Wed, 30 May 2018 19:43:12 +0300 Message-Id: <834liphz6n.fsf@gnu.org> From: Eli Zaretskii To: Michael Mauger In-reply-to: (message from Michael Mauger on Tue, 29 May 2018 22:51:35 -0400) Subject: Re: bug#31446: 26.1; sql-interactive-mode buffer naming is broken References: <83d0xpf47n.fsf@gnu.org> <83fu2jej5t.fsf@gnu.org> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e X-Spam-Score: -5.0 (-----) X-Debbugs-Envelope-To: 31446 Cc: psainty@orcon.net.nz, 31446@debbugs.gnu.org, fgunbin@fastmail.fm X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Eli Zaretskii Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -6.0 (------) > Date: Tue, 29 May 2018 22:51:35 -0400 > From: Michael Mauger > Cc: "31446@debbugs.gnu.org" <31446@debbugs.gnu.org>, > Filipp Gunbin , > bug-gnu-emacs > > I expect to make an initial commit to master in a couple of days of sql.el. > That will be followed up with a commit of improved DOCSTRINGs, tests, > and possibly an Info file. > > I'll leave it to Eli et al. to decide whether the sql.el on master gets merged > into the emacs-26 branch later. Thanks. From debbugs-submit-bounces@debbugs.gnu.org Sat Jun 02 19:47:41 2018 Received: (at 31446) by debbugs.gnu.org; 2 Jun 2018 23:47:41 +0000 Received: from localhost ([127.0.0.1]:59653 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fPGFI-0001KB-Vt for submit@debbugs.gnu.org; Sat, 02 Jun 2018 19:47:41 -0400 Received: from mail2.protonmail.ch ([185.70.40.22]:53661) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fPGFG-0001K2-LV for 31446@debbugs.gnu.org; Sat, 02 Jun 2018 19:47:39 -0400 Date: Sat, 02 Jun 2018 19:47:17 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=protonmail.com; s=default; t=1527983244; bh=SQcGqBaPts8aT2JUx7G6Ss5gtJhzEWt7H35GKHn3pe0=; h=Date:To:From:Reply-To:Subject:In-Reply-To:References:Feedback-ID: From; b=YRoCvXLTFLLQvshtQzVrWCtCFRU1HNh8Tz+s1qS3GFcgwyMy555BxnUFhViWkyocK luI6H43Au+f4TOFkurzBZ/P/S1gShyt5eyzkI/1vVtorvQORcOft/H9zUedtyZQjLb YsSnuDOUDzyNDdnryUDOMbu/oUd1ZSZbvw2TS3nw= To: Eli Zaretskii , "psainty@orcon.net.nz" , "31446@debbugs.gnu.org" <31446@debbugs.gnu.org>, "fgunbin@fastmail.fm" From: Michael Mauger Subject: Re: bug#31446: 26.1; sql-interactive-mode buffer naming is broken Message-ID: In-Reply-To: <834liphz6n.fsf@gnu.org> References: <83fu2jej5t.fsf@gnu.org> <834liphz6n.fsf@gnu.org> Feedback-ID: b6CpL0MxcIA6fpHRkn3ZHzWS0Hoqxbtv_SrHfEzC9D85cLvnRsVk4rKaAOJUw48iy20W0W1VX4whjBYFluIX0w==:Ext:ProtonMail MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-1.1 required=5.0 tests=ALL_TRUSTED,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM autolearn=ham autolearn_force=no version=3.4.1 X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on mail.protonmail.ch X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 31446 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Michael Mauger Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) =E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90 Original Me= ssage =E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90 On May 30, 2018 12:43 PM, Eli Zaretskii wrote: > > Date: Tue, 29 May 2018 22:51:35 -0400 > > From: Michael Mauger mmauger@protonmail.com > >=20 > > I expect to make an initial commit to master in a couple of days of sql= .el. > > > > That will be followed up with a commit of improved DOCSTRINGs, tests, > > and possibly an Info file. > >=20 >=20 > Thanks. I have made a commit that fixes the buffer name handling. This code was=20 intended for 26.1 but obviously missed that. Please review it and let me know what you find. Outstanding work: * There is a bug around locating sql-interactive buffers from a sql buffer;= I=20 know how to fix it, just need to further test the code. * Rewrite the DOCSTRINGs to reflect the improved logic * Add code tests to limit regressions like this in the future * Add a Info file documenting sql-mode and the intended behavior. Thanks and sorry for the bug. =E2=80=8B-- MICHAEL@MAUGER.COM // FSF and EFF member // GNU Emacs sql.el maintainer= =E2=80=8B From debbugs-submit-bounces@debbugs.gnu.org Sun Jun 03 12:30:46 2018 Received: (at 31446) by debbugs.gnu.org; 3 Jun 2018 16:30:46 +0000 Received: from localhost ([127.0.0.1]:60468 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fPVu1-0001pA-Pv for submit@debbugs.gnu.org; Sun, 03 Jun 2018 12:30:45 -0400 Received: from eggs.gnu.org ([208.118.235.92]:51570) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fPVu0-0001oy-H6 for 31446@debbugs.gnu.org; Sun, 03 Jun 2018 12:30:44 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fPVtu-0005dh-Lg for 31446@debbugs.gnu.org; Sun, 03 Jun 2018 12:30:39 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-0.0 required=5.0 tests=BAYES_40 autolearn=disabled version=3.3.2 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:33119) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fPVtp-0005a0-VM; Sun, 03 Jun 2018 12:30:34 -0400 Received: from [176.228.60.248] (port=4229 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1fPVtp-0002O5-5x; Sun, 03 Jun 2018 12:30:33 -0400 Date: Sun, 03 Jun 2018 19:30:39 +0300 Message-Id: <83in6zde8g.fsf@gnu.org> From: Eli Zaretskii To: Michael Mauger In-reply-to: (message from Michael Mauger on Sat, 02 Jun 2018 19:47:17 -0400) Subject: Re: bug#31446: 26.1; sql-interactive-mode buffer naming is broken References: <83fu2jej5t.fsf@gnu.org> <834liphz6n.fsf@gnu.org> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e X-Spam-Score: -5.0 (-----) X-Debbugs-Envelope-To: 31446 Cc: psainty@orcon.net.nz, 31446@debbugs.gnu.org, fgunbin@fastmail.fm X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Eli Zaretskii Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -6.0 (------) > Date: Sat, 02 Jun 2018 19:47:17 -0400 > From: Michael Mauger > > I have made a commit that fixes the buffer name handling. This code was > intended for 26.1 but obviously missed that. Please review it and let me > know what you find. Thanks. Please in the future include in the log message a ChangeLog-style list of specific changes you made. > Outstanding work: > * There is a bug around locating sql-interactive buffers from a sql buffer; I > know how to fix it, just need to further test the code. > * Rewrite the DOCSTRINGs to reflect the improved logic > * Add code tests to limit regressions like this in the future > * Add a Info file documenting sql-mode and the intended behavior. Great, thanks in advance. From debbugs-submit-bounces@debbugs.gnu.org Sun Jun 03 16:47:20 2018 Received: (at 31446) by debbugs.gnu.org; 3 Jun 2018 20:47:20 +0000 Received: from localhost ([127.0.0.1]:60599 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fPZuK-0003W4-2C for submit@debbugs.gnu.org; Sun, 03 Jun 2018 16:47:20 -0400 Received: from mail4.protonmail.ch ([185.70.40.27]:27453) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fPZuI-0003Vw-Tn for 31446@debbugs.gnu.org; Sun, 03 Jun 2018 16:47:19 -0400 Date: Sun, 03 Jun 2018 16:47:09 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=protonmail.com; s=default; t=1528058831; bh=0mrzizBPfWvtmP3TyKNA4QiG1Y+dcHVr5sTqnSCl4dE=; h=Date:To:From:Cc:Reply-To:Subject:In-Reply-To:References: Feedback-ID:From; b=K/5WeelRu7mapbvKq/P6ZoIpYBeif62uJTjLhtBy2hEKv2WdqYQAmSqLKDYk3H1ir Y1VrX/KjHEJ6aFoaCpC3WUlo+evxsyKk3bReDN6f+ko62rU1HczA9IDoBwr7YEapsU puHBnzSInc57WKhakUmONTOdkhhe8JQuK3KVN72Q= To: Eli Zaretskii From: Michael Mauger Subject: Re: bug#31446: 26.1; sql-interactive-mode buffer naming is broken Message-ID: In-Reply-To: <83in6zde8g.fsf@gnu.org> References: <834liphz6n.fsf@gnu.org> <83in6zde8g.fsf@gnu.org> Feedback-ID: b6CpL0MxcIA6fpHRkn3ZHzWS0Hoqxbtv_SrHfEzC9D85cLvnRsVk4rKaAOJUw48iy20W0W1VX4whjBYFluIX0w==:Ext:ProtonMail MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-1.1 required=5.0 tests=ALL_TRUSTED,BAYES_40, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM autolearn=ham autolearn_force=no version=3.4.1 X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on mail.protonmail.ch X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 31446 Cc: "psainty@orcon.net.nz" , "31446@debbugs.gnu.org" <31446@debbugs.gnu.org>, "fgunbin@fastmail.fm" X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Michael Mauger Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) =E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90 Original Me= ssage =E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90=E2=80=90 On June 3, 2018 12:30 PM, Eli Zaretskii wrote: >=20 > > From: Michael Mauger mmauger@protonmail.com > >=20 > > I have made a commit that fixes the buffer name handling. This code was > > intended for 26.1 but obviously missed that. Please review it and let m= e > > know what you find. >=20 > Thanks. Please in the future include in the log message a > ChangeLog-style list of specific changes you made. Damn, I spent an afternoon writing up the ChangeLog out of habit=20 and then forgot it! It doesn't appear that I can amend the commit at this point, should=20 I submit an essentially empty commit with the ChangeLog (and an appropriate cross reference to the original commit), attach it to my=20 next commit, or just forget the whole thing and leave a note for=20 myself to be more cautious when I commit? =E2=80=8B--=20 MICHAEL@MAUGER.COM // FSF and EFF member // GNU Emacs sql.el maintainer= =E2=80=8B From debbugs-submit-bounces@debbugs.gnu.org Sun Jun 03 22:32:19 2018 Received: (at 31446) by debbugs.gnu.org; 4 Jun 2018 02:32:19 +0000 Received: from localhost ([127.0.0.1]:60728 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fPfIB-00071v-CT for submit@debbugs.gnu.org; Sun, 03 Jun 2018 22:32:19 -0400 Received: from eggs.gnu.org ([208.118.235.92]:37422) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fPfI9-00071e-KE for 31446@debbugs.gnu.org; Sun, 03 Jun 2018 22:32:18 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fPfI3-0007m5-NC for 31446@debbugs.gnu.org; Sun, 03 Jun 2018 22:32:12 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50 autolearn=disabled version=3.3.2 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:39885) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fPfHy-0007kz-3W; Sun, 03 Jun 2018 22:32:06 -0400 Received: from [176.228.60.248] (port=1080 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1fPfHx-0006gJ-7I; Sun, 03 Jun 2018 22:32:05 -0400 Date: Mon, 04 Jun 2018 05:32:12 +0300 Message-Id: <83d0x7cmdv.fsf@gnu.org> From: Eli Zaretskii To: Michael Mauger In-reply-to: (message from Michael Mauger on Sun, 03 Jun 2018 16:47:09 -0400) Subject: Re: bug#31446: 26.1; sql-interactive-mode buffer naming is broken References: <834liphz6n.fsf@gnu.org> <83in6zde8g.fsf@gnu.org> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e X-Spam-Score: -5.0 (-----) X-Debbugs-Envelope-To: 31446 Cc: psainty@orcon.net.nz, 31446@debbugs.gnu.org, fgunbin@fastmail.fm X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Eli Zaretskii Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -6.0 (------) > Date: Sun, 03 Jun 2018 16:47:09 -0400 > From: Michael Mauger > Cc: "psainty@orcon.net.nz" , "31446@debbugs.gnu.org" <31446@debbugs.gnu.org>, "fgunbin@fastmail.fm" > > Damn, I spent an afternoon writing up the ChangeLog out of habit > and then forgot it! > > It doesn't appear that I can amend the commit at this point, should > I submit an essentially empty commit with the ChangeLog (and an > appropriate cross reference to the original commit), attach it to my > next commit, or just forget the whole thing and leave a note for > myself to be more cautious when I commit? The latter, I think. It isn't a catastrophe, anyway. From debbugs-submit-bounces@debbugs.gnu.org Mon Jun 04 06:16:09 2018 Received: (at 31446) by debbugs.gnu.org; 4 Jun 2018 10:16:09 +0000 Received: from localhost ([127.0.0.1]:60906 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fPmX3-0007g2-H9 for submit@debbugs.gnu.org; Mon, 04 Jun 2018 06:16:09 -0400 Received: from smtp-3.orcon.net.nz ([60.234.4.44]:36433) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fPmX1-0007fs-Bo for 31446@debbugs.gnu.org; Mon, 04 Jun 2018 06:16:07 -0400 Received: from [10.253.37.70] (port=55171 helo=webmail.orcon.net.nz) by smtp-3.orcon.net.nz with esmtpa (Exim 4.86_2) (envelope-from ) id 1fPmWx-00052Y-Av; Mon, 04 Jun 2018 22:16:03 +1200 Received: from [150.107.175.190] via [10.253.37.253] by webmail.orcon.net.nz with HTTP (HTTP/1.1 POST); Mon, 04 Jun 2018 22:16:03 +1200 MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII; format=flowed Content-Transfer-Encoding: 7bit Date: Mon, 04 Jun 2018 22:16:03 +1200 From: Phil Sainty To: Michael Mauger Subject: Re: bug#31446: 26.1; sql-interactive-mode buffer naming is broken In-Reply-To: References: <83fu2jej5t.fsf@gnu.org> <834liphz6n.fsf@gnu.org> Message-ID: X-Sender: psainty@orcon.net.nz User-Agent: Orcon Webmail X-GeoIP: -- X-Spam_score: -2.9 X-Spam_score_int: -28 X-Spam_bar: -- X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 31446 Cc: 31446@debbugs.gnu.org, Eli Zaretskii , fgunbin@fastmail.fm, bug-gnu-emacs X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) On 2018-06-03 11:47, Michael Mauger wrote: > I have made a commit that fixes the buffer name handling. This code > was intended for 26.1 but obviously missed that. Please review it > and let me know what you find. Buffer naming behaviour seems good to me at first look. Running sql-postgres (with no prefix argument) when there is an existing SQLi buffer now displays the buffer but does not select the window, which seems like a bug? -Phil > Outstanding work: > * There is a bug around locating sql-interactive buffers from a sql > buffer; I know how to fix it, just need to further test the code. > * Rewrite the DOCSTRINGs to reflect the improved logic > * Add code tests to limit regressions like this in the future > * Add a Info file documenting sql-mode and the intended behavior. From debbugs-submit-bounces@debbugs.gnu.org Mon Jun 04 13:45:31 2018 Received: (at 31446) by debbugs.gnu.org; 4 Jun 2018 17:45:31 +0000 Received: from localhost ([127.0.0.1]:33612 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fPtXv-0004I1-2B for submit@debbugs.gnu.org; Mon, 04 Jun 2018 13:45:31 -0400 Received: from out1-smtp.messagingengine.com ([66.111.4.25]:43399) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fPtXr-0004Hs-Fg for 31446@debbugs.gnu.org; Mon, 04 Jun 2018 13:45:27 -0400 Received: from compute1.internal (compute1.nyi.internal [10.202.2.41]) by mailout.nyi.internal (Postfix) with ESMTP id 058D521D1A; Mon, 4 Jun 2018 13:45:27 -0400 (EDT) Received: from mailfrontend1 ([10.202.2.162]) by compute1.internal (MEProxy); Mon, 04 Jun 2018 13:45:27 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fastmail.fm; h= cc:content-type:date:from:in-reply-to:message-id:mime-version :references:subject:to:x-me-sender:x-me-sender:x-sasl-enc; s= fm3; bh=+m340NPfrNWIf5ozp29MShgNe4uI5aysx/fO74nvxpE=; b=jZH+DT4S hbYpFN4KCXHTdT0f0q5jXXQxX4GEM1edv3UuPKIVRA+qvqLFrFPKAWbi+WCULlEb h/iRnCFGQDBHf3QfcTL/O/+ke5pZLv7aIS2NWqqsCETo5v8+v1A91zWGmvu8REQy qgwPWvfcg+xYeXBRkUE+bPfczqm0tAlSWYW0b2hSJf8zNKp2M9lv3wpSZMs7DUGb QCeJ6wn8vQlwdlLsF3IAHsGeUQnajUTz4FgfT+jcJ3ZX67QzgTc6zGNKFuub4Ok4 Rv+rYg0JFESfcyOoc5/ldPQrkWgbHBRmKrApjZRkZn7PabXK1DiKEilh8VOE9Qqg tO9eALl/eI0eWQ== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-sender :x-me-sender:x-sasl-enc; s=fm2; bh=+m340NPfrNWIf5ozp29MShgNe4uI5 aysx/fO74nvxpE=; b=PtMJxirft9WaI2lq2iL5+EQg8liud6rMGFkae4DQsmk/G +oUCC5R6a+1GSHNYhea6KrFchaAwPoMycSmjbILv85vn+38rtHC1K6LPL2J9S9qV 9/nIgIresEDnQGZ/i8sWjElBOTG7c2Kdxa0vPCnq0o1u93eTlTW09DBEGVIoS9z/ MrMvnkOOfv4zuQA7rr3aexUgMi23p8Al7wI/eHbklaqU2bpAarPG+sE0d+fpaD49 EB2KwHtitJiXcNuIsbdl5NQ+iEhhjANNIilQAnAaAZMZBCmypTXZCgu5KmOYA/O2 dCfL9kxgJXyPw4mlYohiLrZXKS11GmFNkpMWFoDFA== X-ME-Proxy: X-ME-Proxy: X-ME-Proxy: X-ME-Proxy: X-ME-Proxy: X-ME-Proxy: X-ME-Sender: Received: from fgunbin.playteam.ru (unknown [94.25.218.10]) by mail.messagingengine.com (Postfix) with ESMTPA id E82B9E452C; Mon, 4 Jun 2018 13:45:25 -0400 (EDT) From: Filipp Gunbin To: Michael Mauger Subject: Re: bug#31446: 26.1; sql-interactive-mode buffer naming is broken In-Reply-To: (Michael Mauger's message of "Sat, 02 Jun 2018 19:47:17 -0400") References: <83fu2jej5t.fsf@gnu.org> <834liphz6n.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (darwin) Date: Mon, 04 Jun 2018 20:45:23 +0300 Message-ID: MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 31446 Cc: "psainty@orcon.net.nz" , "31446@debbugs.gnu.org" <31446@debbugs.gnu.org>, Eli Zaretskii X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) On 02/06/2018 19:47 -0400, Michael Mauger wrote: > I have made a commit that fixes the buffer name handling. This code was > intended for 26.1 but obviously missed that. Please review it and let me > know what you find. I've tested it a bit, LGTM. Thanks. From debbugs-submit-bounces@debbugs.gnu.org Wed Apr 24 21:13:56 2019 Received: (at 31446-close) by debbugs.gnu.org; 25 Apr 2019 01:13:56 +0000 Received: from localhost ([127.0.0.1]:56920 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hJSxX-0000EB-Sb for submit@debbugs.gnu.org; Wed, 24 Apr 2019 21:13:56 -0400 Received: from mail-40132.protonmail.ch ([185.70.40.132]:53117) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hJSxU-0000Dx-Ul for 31446-close@debbugs.gnu.org; Wed, 24 Apr 2019 21:13:54 -0400 Date: Thu, 25 Apr 2019 01:13:39 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=protonmail.com; s=default; t=1556154826; bh=fgY3npzzgiXfSnqe42aklK2tow4o7hzQ/79+4ZrrWAE=; h=Date:To:From:Reply-To:Subject:Feedback-ID:From; b=VLu/KIiHk9LBIbzKilFOPkDcgf9Dt/ZLiPia+9UzX9LGrgJAxDeMloM5B2sdnD3Qy 15hAwvMZn3MgnvqlSadXmaRMJpM8yVaIc6y17hPRuW+l7hNnCIm65weCohWn73+egg HLA7FpP+UzktOaVPpRgk7loEwCvGlB+WCqFjDKVc= To: "31446-close@debbugs.gnu.org" <31446-close@debbugs.gnu.org> From: Michael Mauger Subject: sql-interactive-mode buffer naming is broken Message-ID: Feedback-ID: b6CpL0MxcIA6fpHRkn3ZHzWS0Hoqxbtv_SrHfEzC9D85cLvnRsVk4rKaAOJUw48iy20W0W1VX4whjBYFluIX0w==:Ext:ProtonMail MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="b1_95eca1bc411af6bbd88b13d0d3a0a2be" X-Spam-Status: No, score=-1.2 required=7.0 tests=ALL_TRUSTED,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,HTML_MESSAGE autolearn=ham autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on mail.protonmail.ch X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 31446-close X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Michael Mauger Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) This is a multi-part message in MIME format. --b1_95eca1bc411af6bbd88b13d0d3a0a2be Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: base64 QmFzZWQgb24gYSBwcmV2aW91cyBjb21taXQgYW5kIHRoaXMgY29tbWl0LCBidWZmZXIgbmFtaW5n IHNob3VsZCBiZSBtb3JlIGNvbnNpc3RlbnQgYW5kIGNvcnJlY3QuCkFkZGVkIHRlc3RzIHRvIGlu c3VyZSBJIGRvbid0IG1lc3MgdGhlbSB1cCBhZ2FpbiEKCi0tCk1JQ0hBRUxATUFVR0VSLkNPTSAv LyBGU0YgYW5kIEVGRiBtZW1iZXIgLy8gR05VIEVtYWNzIHNxbC5lbCBtYWludGFpbmVy --b1_95eca1bc411af6bbd88b13d0d3a0a2be Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: base64 PGRpdj5CYXNlZCBvbiBhIHByZXZpb3VzIGNvbW1pdCBhbmQgdGhpcyBjb21taXQsIGJ1ZmZlciBu YW1pbmcgc2hvdWxkIGJlIG1vcmUgY29uc2lzdGVudCBhbmQgY29ycmVjdC4gPGJyPjwvZGl2Pjxk aXY+QWRkZWQgdGVzdHMgdG8gaW5zdXJlIEkgZG9uJ3QgbWVzcyB0aGVtIHVwIGFnYWluISA8YnI+ PC9kaXY+PGRpdj48YnI+PC9kaXY+PGRpdiBjbGFzcz0icHJvdG9ubWFpbF9zaWduYXR1cmVfYmxv Y2siPjxkaXYgY2xhc3M9InByb3Rvbm1haWxfc2lnbmF0dXJlX2Jsb2NrLXVzZXIiPjxkaXY+LS0g PGJyPjwvZGl2PjxkaXY+TUlDSEFFTEBNQVVHRVIuQ09NIC8vIEZTRiBhbmQgRUZGIG1lbWJlciAv LyBHTlUgRW1hY3Mgc3FsLmVsIG1haW50YWluZXI8YnI+PC9kaXY+PC9kaXY+PGRpdiBjbGFzcz0i cHJvdG9ubWFpbF9zaWduYXR1cmVfYmxvY2stcHJvdG9uIHByb3Rvbm1haWxfc2lnbmF0dXJlX2Js b2NrLWVtcHR5Ij48YnI+PC9kaXY+PC9kaXY+PGRpdj48YnI+PC9kaXY+ --b1_95eca1bc411af6bbd88b13d0d3a0a2be-- From unknown Sun Jun 15 08:50:12 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Thu, 23 May 2019 11:24:06 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator