X-Loop: help-debbugs@HIDDEN Subject: bug#69420: 29.2; iSQL point/process-mark fix Resent-From: Gary Hollis <ghollisjr@HIDDEN> Original-Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> Resent-CC: bug-gnu-emacs@HIDDEN Resent-Date: Tue, 27 Feb 2024 05:04:01 +0000 Resent-Message-ID: <handler.69420.B.170901022625185 <at> debbugs.gnu.org> Resent-Sender: help-debbugs@HIDDEN X-GNU-PR-Message: report 69420 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: 69420 <at> debbugs.gnu.org X-Debbugs-Original-To: bug-gnu-emacs@HIDDEN Received: via spool by submit <at> debbugs.gnu.org id=B.170901022625185 (code B ref -1); Tue, 27 Feb 2024 05:04:01 +0000 Received: (at submit) by debbugs.gnu.org; 27 Feb 2024 05:03:46 +0000 Received: from localhost ([127.0.0.1]:46574 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1repd3-0006Y7-7p for submit <at> debbugs.gnu.org; Tue, 27 Feb 2024 00:03:46 -0500 Received: from lists.gnu.org ([209.51.188.17]:37944) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <ghollisjr@HIDDEN>) id 1repW9-00069l-SQ for submit <at> debbugs.gnu.org; Mon, 26 Feb 2024 23:56:38 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from <ghollisjr@HIDDEN>) id 1repVj-0006LF-RR for bug-gnu-emacs@HIDDEN; Mon, 26 Feb 2024 23:56:11 -0500 Received: from mail-yw1-x1133.google.com ([2607:f8b0:4864:20::1133]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from <ghollisjr@HIDDEN>) id 1repVh-0004hC-Kp for bug-gnu-emacs@HIDDEN; Mon, 26 Feb 2024 23:56:11 -0500 Received: by mail-yw1-x1133.google.com with SMTP id 00721157ae682-6092387bdd0so4575107b3.3 for <bug-gnu-emacs@HIDDEN>; Mon, 26 Feb 2024 20:56:08 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1709009767; x=1709614567; darn=gnu.org; h=content-transfer-encoding:from:content-language:subject:to :user-agent:mime-version:date:message-id:from:to:cc:subject:date :message-id:reply-to; bh=cKF4AdeuzY+J1AcLQk1F1CT4G4K6L3nx9zKzVuxShus=; b=i2IrybCM/7EMvZQuR2yUiAVvFSMhLHFNytKS5ZHjd/TdossXPu+qt8XiyD8cs/sVxZ 1JHrRrDTc53dRZs7Ixvo8sgqV4gEzcGkY9Qsn8lnK8FsvdjG3lw7penPSO4ZS1D7Bjzo ONtHakTIyaYM0Sbo3ua05YQsm0VrWx7HPTasO0OQj6LtmTSXTQXdIAQRbRW0jdpGLTno HotB615wqG6hDOP2+TPW6av/E9X3oyBWxC9Fs7ENzeIzSsfjxS+FMGGrgivDe682oHzr 9VPeeYSt1yvNO/qTXNAdqls1BiK3frULzlGgAza/58rmLWAxKw14nZGBRnOm/B+O50GH XI+w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1709009767; x=1709614567; h=content-transfer-encoding:from:content-language:subject:to :user-agent:mime-version:date:message-id:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=cKF4AdeuzY+J1AcLQk1F1CT4G4K6L3nx9zKzVuxShus=; b=rQbg5QK9xHxYvxdTuu+NfX48DuYo8VI3EjanRbZhSE3I4Qd2XCuLO+ZlCMn7bU81st GDaaADOyBBN12xLiMvCh91DxbtJvGoNOBjZUetywSivGx6albAgWFy6Dfw2Vue81ykvf CWTZIHQWX0oDgesxKT+EZ1Vw9/WzUsxVYQcTehQw/y2OV7IkUPXCcSGgdnqUrFu/1k0Q AFlX+2KDUB/pDCTyCgNE0+Gx+4ceHB2/V1/bcLr0kKkl7mTMDZcvgoIpTONIqQC6BWVV aJC9depo4vf7s0o0oz+UN5DMRM1TcmmSE7nrHaMMtOTtGnxemlcARBTSpf0fiIaB67Tu bfcA== X-Gm-Message-State: AOJu0YzoPV08POYuij4cYGaRAKWBoWltQ5Hm90/0GRPzKdQwSPgrKeSQ xJ9tBN3WOgI5Wl+LH/A0kt3OLSIV87tPwpq1AO+y1O6nsKvzSzoX5tsXG6jX X-Google-Smtp-Source: AGHT+IGF972p/wZPw3nFOuyFm7bN7Ck1W7aFIdP17BM2Dl+2jF9MnMxbayiGbAD7iRZd9Kt9/Nl16A== X-Received: by 2002:a05:690c:9d:b0:607:9dda:676c with SMTP id be29-20020a05690c009d00b006079dda676cmr1392372ywb.18.1709009767263; Mon, 26 Feb 2024 20:56:07 -0800 (PST) Received: from [192.168.1.3] (173-093-201-060.res.spectrum.com. [173.93.201.60]) by smtp.gmail.com with ESMTPSA id x21-20020a0dd515000000b00607fab8965esm1572425ywd.32.2024.02.26.20.56.06 for <bug-gnu-emacs@HIDDEN> (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 26 Feb 2024 20:56:06 -0800 (PST) Message-ID: <2110e7d1-153c-412a-a0dc-37531a0b6d84@HIDDEN> Date: Mon, 26 Feb 2024 23:56:05 -0500 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Content-Language: en-US From: Gary Hollis <ghollisjr@HIDDEN> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Received-SPF: pass client-ip=2607:f8b0:4864:20::1133; envelope-from=ghollisjr@HIDDEN; helo=mail-yw1-x1133.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: -1.3 (-) X-Mailman-Approved-At: Tue, 27 Feb 2024 00:03:43 -0500 X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -2.3 (--) When the point is not at the very end of the iSQL buffer, the process-mark is not kept in a reasonable state if sql-send-string is called. Example to reproduce bug: 1. Open a sql-mode buffer. 2. Connect to a SQL database of choice. 3. Move the point of the iSQL buffer to the top, e.g. with M-< 4. Send good queries via sql-send-string, sql-send-region etc. 5. In iSQL buffer, move point to end, e.g. with M-> 6. Enter a good query. Expected result: The new query successfully sends and sql process returns output. Actual result: Whatever contents had been output from the sql-send-string, sql-send-region etc. will be sent along with the new query. To fix: a call to (end-of-buffer) can be placed within the (save-excursion ...) context before sending any input in the sql-send-string function, e.g. ;; from sql.el with fix for bug added with BUG FIX comment: (defun sql-send-string (str) "Send the string STR to the SQL process." (interactive "sSQL Text: ") (let ((comint-input-sender-no-newline nil) (s (replace-regexp-in-string "[[:space:]\n\r]+\\'" "" str))) (if (sql-buffer-live-p sql-buffer) (progn ;; Ignore the hoping around... (save-excursion ;; Set product context (with-current-buffer sql-buffer (end-of-buffer) ; BUG FIX: correct point before sending input (when sql-debug-send (message ">>SQL> %S" s)) (insert "\n") (comint-set-process-mark) ;; Send the string (trim the trailing whitespace) (sql-input-sender (get-buffer-process (current-buffer)) s) ;; Send a command terminator if we must (sql-send-magic-terminator sql-buffer s sql-send-terminator) (when sql-pop-to-buffer-after-send-region (message "Sent string to buffer %s" sql-buffer)))) ;; Display the sql buffer (sql-display-buffer sql-buffer)) ;; We don't have no stinkin' sql (user-error "No SQL process started")))) In GNU Emacs 29.2 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.24.40, cairo version 1.18.0) Windowing system distributor 'The X.Org Foundation', version 11.0.12101011 System Description: Arch Linux Configured using: 'configure --sysconfdir=/etc --prefix=/usr --libexecdir=/usr/lib --with-tree-sitter --localstatedir=/var --with-cairo --disable-build-details --with-harfbuzz --with-libsystemd --with-modules --with-x-toolkit=gtk3 'CFLAGS=-march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security -fstack-clash-protection -fcf-protection -g -ffile-prefix-map=/build/emacs/src=/usr/src/debug/emacs -flto=auto' 'LDFLAGS=-Wl,-O1,--sort-common,--as-needed,-z,relro,-z,now -flto=auto'' Configured features: ACL CAIRO DBUS FREETYPE GIF GLIB GMP GNUTLS GPM GSETTINGS HARFBUZZ JPEG JSON LCMS2 LIBOTF LIBSYSTEMD LIBXML2 M17N_FLT MODULES NOTIFY INOTIFY PDUMPER PNG RSVG SECCOMP SOUND SQLITE3 THREADS TIFF TOOLKIT_SCROLL_BARS TREE_SITTER WEBP X11 XDBE XIM XINPUT2 XPM GTK3 ZLIB Important settings: value of $LANG: en_US.UTF-8 value of $XMODIFIERS: @im=ibus locale-coding-system: utf-8-unix Major mode: Lisp Interaction Minor modes in effect: recentf-mode: t server-mode: t form-feed-mode: t shell-dirtrack-mode: t pyvenv-mode: t ivy-mode: t delete-selection-mode: t projectile-mode: t global-auto-revert-mode: t global-company-mode: t company-mode: t global-display-line-numbers-mode: t display-line-numbers-mode: t tooltip-mode: t global-eldoc-mode: t eldoc-mode: t show-paren-mode: t electric-indent-mode: t mouse-wheel-mode: t tool-bar-mode: t prettify-symbols-mode: t menu-bar-mode: t file-name-shadow-mode: t global-font-lock-mode: t font-lock-mode: t blink-cursor-mode: t column-number-mode: t line-number-mode: t transient-mark-mode: t auto-composition-mode: t auto-encryption-mode: t auto-compression-mode: t Load-path shadows: ~/.emacs.d/lisp/glsl-mode hides /home/ghollisjr/.emacs.d/elpa/glsl-mode-20210808.1945/glsl-mode ~/.emacs.d/lisp/popup hides /home/ghollisjr/.emacs.d/elpa/popup-20221231.1634/popup /home/ghollisjr/src/slime/slime-tests hides /home/ghollisjr/.emacs.d/elpa/slime-20230707.1938/slime-tests /home/ghollisjr/src/slime/slime hides /home/ghollisjr/.emacs.d/elpa/slime-20230707.1938/slime /home/ghollisjr/src/slime/slime-autoloads hides /home/ghollisjr/.emacs.d/elpa/slime-20230707.1938/slime-autoloads /home/ghollisjr/.emacs.d/elpa/maxima-20230529.1658/maxima-font-lock hides /usr/share/emacs/site-lisp/maxima/maxima-font-lock /home/ghollisjr/.emacs.d/elpa/maxima-20230529.1658/maxima hides /usr/share/emacs/site-lisp/maxima/maxima /home/ghollisjr/.emacs.d/elpa/csharp-mode-20221126.2005/csharp-mode hides /usr/share/emacs/29.2/lisp/progmodes/csharp-mode Features: (shadow sort mail-extr emacsbug message yank-media rfc822 mml mml-sec epa epg rfc6068 epg-config mm-decode mm-bodies mm-encode mail-parse rfc2231 mailabbrev gmm-utils mailheader sendmail rfc2047 rfc2045 ietf-drums goto-addr flyspell ispell jka-compr apropos face-remap misearch multi-isearch thai-util thai-word mule-util lao-util vc-hg vc-git vc-bzr vc-src vc-sccs vc-svn vc-cvs vc-rcs log-view pcvs-util vc vc-dispatcher enriched sql-indent sql-datum sql view recentf tree-widget bookmark server form-feed company-oddmuse company-keywords make-mode company-etags company-gtags company-dabbrev-code company-dabbrev company-files company-clang company-cmake company-semantic company-template company-bbdb use-package-core bash-completion shell pcomplete sh-script executable prettify-math-mode pgformatter ucsf-evan ffap multiple-cursors mc-separate-operations rectangular-region-mode mc-mark-pop mc-edit-lines mc-hide-unmatched-lines-mode mc-mark-more mc-cycle-cursors multiple-cursors-core rect yasnippet cl-extra highlight-indentation flymake-proc flymake warnings company-capf help-fns radix-tree help-mode elpy elpy-rpc pyvenv eshell esh-cmd esh-ext esh-opt esh-proc esh-io esh-arg esh-module esh-groups esh-util elpy-shell elpy-profile elpy-django s elpy-refactor diff-mode ido hideshow files-x cus-edit cus-load ivy delsel ivy-faces ivy-overlay colir projectile skeleton ibuf-macs find-dired dired dired-loaddefs lisp-mnt grep ibuf-ext ibuffer ibuffer-loaddefs opencl-mode align find-file glsl-mode cmake-mode rst qml-mode js c-ts-common cc-mode cc-fonts cc-guess cc-menus cc-cmds cc-styles cc-align cc-engine cc-vars cc-defs css-mode smie sgml-mode facemenu imenu eww xdg url-queue shr pixel-fill kinsoku url-file svg xml dom puny mm-url gnus nnheader gnus-util time-date mail-utils range wid-edit mm-util mail-prsvr color web-mode disp-table autorevert filenotify python-black reformatter python compat treesit dash slime-company derived company pcase slime-fancy slime-indentation slime-cl-indent cl-indent slime-trace-dialog slime-fontifying-fu slime-package-fu slime-references slime-compiler-notes-tree advice slime-scratch slime-presentations bridge slime-macrostep macrostep slime-mdot-fu slime-enclosing-context slime-fuzzy slime-fancy-trace slime-fancy-inspector slime-c-p-c slime-editing-commands slime-autodoc slime-repl slime-parse slime easy-mmode compile text-property-search etags fileloop generator xref project arc-mode archive-mode noutline outline icons pp comint ansi-osc ansi-color ring hyperspec thingatpt display-line-numbers finder-inf ede/auto eieio-base ein-autoloads deferred-autoloads anaphora-autoloads rx polymode-autoloads simple-httpd-autoloads slime-autoloads websocket-autoloads with-editor-autoloads info compat-autoloads zmq-autoloads package browse-url url url-proxy url-privacy url-expand url-methods url-history url-cookie generate-lisp-file url-domsuf url-util mailcap url-handlers url-parse auth-source cl-seq eieio eieio-core cl-macs password-cache json subr-x map byte-opt gv bytecomp byte-compile url-vars cl-loaddefs cl-lib rmc iso-transl tooltip cconv eldoc paren electric uniquify ediff-hook vc-hooks lisp-float-type elisp-mode 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 lisp-mode prog-mode register page tab-bar menu-bar rfn-eshadow isearch easymenu timer select scroll-bar mouse jit-lock font-lock syntax font-core term/tty-colors frame minibuffer nadvice seq simple cl-generic indonesian philippine 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 emoji-zwj charscript charprop case-table epa-hook jka-cmpr-hook help abbrev obarray oclosure cl-preloaded button loaddefs theme-loaddefs faces cus-face macroexp files window text-properties overlay sha1 md5 base64 format env code-pages mule custom widget keymap hashtable-print-readable backquote threads dbusbind inotify lcms2 dynamic-setting system-font-setting font-render-setting cairo move-toolbar gtk x-toolkit xinput2 x multi-tty make-network-process emacs) Memory information: ((conses 16 653922 33278) (symbols 48 36133 0) (strings 32 123994 8934) (string-bytes 1 4062606) (vectors 16 49840) (vector-slots 8 650455 27338) (floats 8 292 333) (intervals 56 8562 0) (buffers 984 16))
Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.505 (Entity 5.505) Content-Type: text/plain; charset=utf-8 X-Loop: help-debbugs@HIDDEN From: help-debbugs@HIDDEN (GNU bug Tracking System) To: Gary Hollis <ghollisjr@HIDDEN> Subject: bug#69420: Acknowledgement (29.2; iSQL point/process-mark fix) Message-ID: <handler.69420.B.170901022625185.ack <at> debbugs.gnu.org> References: <2110e7d1-153c-412a-a0dc-37531a0b6d84@HIDDEN> X-Gnu-PR-Message: ack 69420 X-Gnu-PR-Package: emacs Reply-To: 69420 <at> debbugs.gnu.org Date: Tue, 27 Feb 2024 05:04:02 +0000 Thank you for filing a new bug report with debbugs.gnu.org. This is an automatically generated reply to let you know your message has been received. Your message is being forwarded to the package maintainers and other interested parties for their attention; they will reply in due course. Your message has been sent to the package maintainer(s): bug-gnu-emacs@HIDDEN If you wish to submit further information on this problem, please send it to 69420 <at> debbugs.gnu.org. Please do not send mail to help-debbugs@HIDDEN unless you wish to report a problem with the Bug-tracking system. --=20 69420: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D69420 GNU Bug Tracking System Contact help-debbugs@HIDDEN with problems
X-Loop: help-debbugs@HIDDEN Subject: bug#69420: 29.2; iSQL point/process-mark fix Resent-From: Eli Zaretskii <eliz@HIDDEN> Original-Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> Resent-CC: bug-gnu-emacs@HIDDEN Resent-Date: Tue, 27 Feb 2024 08:15:01 +0000 Resent-Message-ID: <handler.69420.B69420.170902165329541 <at> debbugs.gnu.org> Resent-Sender: help-debbugs@HIDDEN X-GNU-PR-Message: followup 69420 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Gary Hollis <ghollisjr@HIDDEN>, Michael Mauger <michael@HIDDEN> Cc: 69420 <at> debbugs.gnu.org Received: via spool by 69420-submit <at> debbugs.gnu.org id=B69420.170902165329541 (code B ref 69420); Tue, 27 Feb 2024 08:15:01 +0000 Received: (at 69420) by debbugs.gnu.org; 27 Feb 2024 08:14:13 +0000 Received: from localhost ([127.0.0.1]:60745 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1resbM-0007gK-4x for submit <at> debbugs.gnu.org; Tue, 27 Feb 2024 03:14:13 -0500 Received: from eggs.gnu.org ([209.51.188.92]:33634) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <eliz@HIDDEN>) id 1resbK-0007g5-ST for 69420 <at> debbugs.gnu.org; Tue, 27 Feb 2024 03:14:11 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from <eliz@HIDDEN>) id 1resao-00010W-Ks; Tue, 27 Feb 2024 03:13:39 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-version:References:Subject:In-Reply-To:To:From: Date; bh=3NAMIJeUq7kvJ1M+SIbU27IEBSLbA5w0f6BHs58ymRE=; b=qqS6DpSpjE7LUuUBJf6m 4mKjauJJ6jkgRf0/dS877dRhhQISKydKK8g2QG2m94Uko3Fh0+Mu78sZl3AmQRkm4OdJP02+GpN5j xLqllB0Ew1XXD3eLweMADWAjbee/ID3MdFdWqhqB0faXMsQ4DlxCwXs07UM6TYoQUryAR7T8F983i GsfqJjhkXBWi8HEynuGX+ifGhuYnVtpKtLP7HVj2E8Dr47FrtP4M835K98cvgbQK9V6mrYk2iFc7a H3ta+ajAfOgbBohdXHIpdMuLdrM6WQwyTuw4yoEsizzWiYX3geCgI6xM3Bql3SglPV21Tx35uIvqg qGPEawojLbJLlg==; Date: Tue, 27 Feb 2024 10:13:26 +0200 Message-Id: <864jduuxy1.fsf@HIDDEN> From: Eli Zaretskii <eliz@HIDDEN> In-Reply-To: <2110e7d1-153c-412a-a0dc-37531a0b6d84@HIDDEN> (message from Gary Hollis on Mon, 26 Feb 2024 23:56:05 -0500) References: <2110e7d1-153c-412a-a0dc-37531a0b6d84@HIDDEN> MIME-version: 1.0 Content-type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -3.3 (---) > Date: Mon, 26 Feb 2024 23:56:05 -0500 > From: Gary Hollis <ghollisjr@HIDDEN> > > When the point is not at the very end of the iSQL buffer, the > process-mark is not kept in a reasonable state if sql-send-string is > called. > > Example to reproduce bug: > 1. Open a sql-mode buffer. > 2. Connect to a SQL database of choice. > 3. Move the point of the iSQL buffer to the top, e.g. with M-< > 4. Send good queries via sql-send-string, sql-send-region etc. > 5. In iSQL buffer, move point to end, e.g. with M-> > 6. Enter a good query. > > Expected result: The new query successfully sends and sql process > returns output. > Actual result: Whatever contents had been output from the > sql-send-string, sql-send-region etc. will be sent along with the new query. > > To fix: a call to (end-of-buffer) can be placed within the > (save-excursion ...) context before sending any input in the > sql-send-string function, e.g. > > ;; from sql.el with fix for bug added with BUG FIX comment: > (defun sql-send-string (str) > "Send the string STR to the SQL process." > (interactive "sSQL Text: ") > > (let ((comint-input-sender-no-newline nil) > (s (replace-regexp-in-string "[[:space:]\n\r]+\\'" "" str))) > (if (sql-buffer-live-p sql-buffer) > (progn > ;; Ignore the hoping around... > (save-excursion > ;; Set product context > (with-current-buffer sql-buffer > (end-of-buffer) ; BUG FIX: correct point before sending input > (when sql-debug-send > (message ">>SQL> %S" s)) > (insert "\n") > (comint-set-process-mark) > > ;; Send the string (trim the trailing whitespace) > (sql-input-sender (get-buffer-process (current-buffer)) s) > > ;; Send a command terminator if we must > (sql-send-magic-terminator sql-buffer s sql-send-terminator) > > (when sql-pop-to-buffer-after-send-region > (message "Sent string to buffer %s" sql-buffer)))) > > ;; Display the sql buffer > (sql-display-buffer sql-buffer)) > > ;; We don't have no stinkin' sql > (user-error "No SQL process started")))) > Thanks. Michael, any comments or suggestions?
X-Loop: help-debbugs@HIDDEN Subject: bug#69420: 29.2; iSQL point/process-mark fix Resent-From: Eli Zaretskii <eliz@HIDDEN> Original-Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> Resent-CC: bug-gnu-emacs@HIDDEN Resent-Date: Sat, 09 Mar 2024 08:59:01 +0000 Resent-Message-ID: <handler.69420.B69420.170997470314763 <at> debbugs.gnu.org> Resent-Sender: help-debbugs@HIDDEN X-GNU-PR-Message: followup 69420 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: michael@HIDDEN Cc: ghollisjr@HIDDEN, 69420 <at> debbugs.gnu.org Received: via spool by 69420-submit <at> debbugs.gnu.org id=B69420.170997470314763 (code B ref 69420); Sat, 09 Mar 2024 08:59:01 +0000 Received: (at 69420) by debbugs.gnu.org; 9 Mar 2024 08:58:23 +0000 Received: from localhost ([127.0.0.1]:60620 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1risX8-0003q2-MB for submit <at> debbugs.gnu.org; Sat, 09 Mar 2024 03:58:23 -0500 Received: from eggs.gnu.org ([209.51.188.92]:43326) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <eliz@HIDDEN>) id 1risX7-0003pr-Gu for 69420 <at> debbugs.gnu.org; Sat, 09 Mar 2024 03:58:21 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from <eliz@HIDDEN>) id 1risWV-000151-7L; Sat, 09 Mar 2024 03:57:43 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-version:References:Subject:In-Reply-To:To:From: Date; bh=QSeN0zuhwAb2qYsTlas1qaL/k5axsdDR4pS3HvoZhaE=; b=LA9cfuB2oPnpryRsUTNi 3axXZsRFVEK3p3K33QkO6ImyMR/yJpX4NGtBW1Rrg0yZ8eWYvo+d64TCGTqBJrU6Bcwtrl08WJTWC BFLhQbMI5YHOppgn6sXDACZJdZctve41tkyCMQ33OcQGv/HVbXCok7C2EGo+iZKLdatkEugZ8+oKE ojLe1LWnyQWlkt9F+P9FP5Ku5K9XPSviPdmNMq/FFzP7P7lxkyb4cLb4n7kw6SE6/KZUJTPGm404G T84VNcp8EgVrEz7DAVyrYp4NCB5HNnDjbGkJJTfUetyoQBpmc3pmLfP7RLaCslUv/uvoZI2SCecBm PeRzVFTFM/loJw==; Date: Sat, 09 Mar 2024 10:57:40 +0200 Message-Id: <86le6rye7v.fsf@HIDDEN> From: Eli Zaretskii <eliz@HIDDEN> In-Reply-To: <864jduuxy1.fsf@HIDDEN> (message from Eli Zaretskii on Tue, 27 Feb 2024 10:13:26 +0200) References: <2110e7d1-153c-412a-a0dc-37531a0b6d84@HIDDEN> <864jduuxy1.fsf@HIDDEN> MIME-version: 1.0 Content-type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -3.3 (---) Ping! Michael, any comments? > Cc: 69420 <at> debbugs.gnu.org > Date: Tue, 27 Feb 2024 10:13:26 +0200 > From: Eli Zaretskii <eliz@HIDDEN> > > > Date: Mon, 26 Feb 2024 23:56:05 -0500 > > From: Gary Hollis <ghollisjr@HIDDEN> > > > > When the point is not at the very end of the iSQL buffer, the > > process-mark is not kept in a reasonable state if sql-send-string is > > called. > > > > Example to reproduce bug: > > 1. Open a sql-mode buffer. > > 2. Connect to a SQL database of choice. > > 3. Move the point of the iSQL buffer to the top, e.g. with M-< > > 4. Send good queries via sql-send-string, sql-send-region etc. > > 5. In iSQL buffer, move point to end, e.g. with M-> > > 6. Enter a good query. > > > > Expected result: The new query successfully sends and sql process > > returns output. > > Actual result: Whatever contents had been output from the > > sql-send-string, sql-send-region etc. will be sent along with the new query. > > > > To fix: a call to (end-of-buffer) can be placed within the > > (save-excursion ...) context before sending any input in the > > sql-send-string function, e.g. > > > > ;; from sql.el with fix for bug added with BUG FIX comment: > > (defun sql-send-string (str) > > "Send the string STR to the SQL process." > > (interactive "sSQL Text: ") > > > > (let ((comint-input-sender-no-newline nil) > > (s (replace-regexp-in-string "[[:space:]\n\r]+\\'" "" str))) > > (if (sql-buffer-live-p sql-buffer) > > (progn > > ;; Ignore the hoping around... > > (save-excursion > > ;; Set product context > > (with-current-buffer sql-buffer > > (end-of-buffer) ; BUG FIX: correct point before sending input > > (when sql-debug-send > > (message ">>SQL> %S" s)) > > (insert "\n") > > (comint-set-process-mark) > > > > ;; Send the string (trim the trailing whitespace) > > (sql-input-sender (get-buffer-process (current-buffer)) s) > > > > ;; Send a command terminator if we must > > (sql-send-magic-terminator sql-buffer s sql-send-terminator) > > > > (when sql-pop-to-buffer-after-send-region > > (message "Sent string to buffer %s" sql-buffer)))) > > > > ;; Display the sql buffer > > (sql-display-buffer sql-buffer)) > > > > ;; We don't have no stinkin' sql > > (user-error "No SQL process started")))) > > > > Thanks. > > Michael, any comments or suggestions? > > > >
X-Loop: help-debbugs@HIDDEN Subject: bug#69420: 29.2; iSQL point/process-mark fix Resent-From: Eli Zaretskii <eliz@HIDDEN> Original-Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> Resent-CC: bug-gnu-emacs@HIDDEN Resent-Date: Thu, 21 Mar 2024 08:36:01 +0000 Resent-Message-ID: <handler.69420.B69420.171101012912652 <at> debbugs.gnu.org> Resent-Sender: help-debbugs@HIDDEN X-GNU-PR-Message: followup 69420 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: michael@HIDDEN Cc: ghollisjr@HIDDEN, 69420 <at> debbugs.gnu.org Received: via spool by 69420-submit <at> debbugs.gnu.org id=B69420.171101012912652 (code B ref 69420); Thu, 21 Mar 2024 08:36:01 +0000 Received: (at 69420) by debbugs.gnu.org; 21 Mar 2024 08:35:29 +0000 Received: from localhost ([127.0.0.1]:34222 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1rnDtY-0003I0-UT for submit <at> debbugs.gnu.org; Thu, 21 Mar 2024 04:35:29 -0400 Received: from eggs.gnu.org ([209.51.188.92]:44802) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <eliz@HIDDEN>) id 1rnDtX-0003Ho-32 for 69420 <at> debbugs.gnu.org; Thu, 21 Mar 2024 04:35:27 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from <eliz@HIDDEN>) id 1rnDsn-0000DK-OC; Thu, 21 Mar 2024 04:34:41 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-version:References:Subject:In-Reply-To:To:From: Date; bh=86DDIZwulloe1b8t84P4MqlSsBsVKecML3qdG/cvtHU=; b=YdlWjdGr65I4+nVdnGxd fIqngo3bCvuyWuBqVXUz4U/4murn8OIf2vMFmPi0oqMjoUCt3ly43GXnneX4ln5kcb98VeUyWeDId mM6mnyq+W9FSiUB1v12HbyPMSTTXChP/iSs3uTUt5GEao1DwaXInSJPp7A6Oe0UGL83AAfTS5ntUy dqtdpPyafdmkHBUMh7gxen0AWkPAYJBmaNgOwQbEDthnklIr4mSMMBR8/nfIFeWxf4MvvRf35QVIB PRBAPfkqLr0DC+gCUTQ02cs1KWbicF81HNMLvT68EM5xd9dIjIcH+BOCqpz4gOCcRmVBFIJH3JNff 83CB/ELTNEvbBQ==; Date: Thu, 21 Mar 2024 10:34:38 +0200 Message-Id: <86frwk2db5.fsf@HIDDEN> From: Eli Zaretskii <eliz@HIDDEN> In-Reply-To: <86le6rye7v.fsf@HIDDEN> (message from Eli Zaretskii on Sat, 09 Mar 2024 10:57:40 +0200) References: <2110e7d1-153c-412a-a0dc-37531a0b6d84@HIDDEN> <864jduuxy1.fsf@HIDDEN> <86le6rye7v.fsf@HIDDEN> MIME-version: 1.0 Content-type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -3.3 (---) Ping! Ping! Michael, would you please responds and comment on this issue? > Cc: ghollisjr@HIDDEN, 69420 <at> debbugs.gnu.org > Date: Sat, 09 Mar 2024 10:57:40 +0200 > From: Eli Zaretskii <eliz@HIDDEN> > > Ping! Michael, any comments? > > > Cc: 69420 <at> debbugs.gnu.org > > Date: Tue, 27 Feb 2024 10:13:26 +0200 > > From: Eli Zaretskii <eliz@HIDDEN> > > > > > Date: Mon, 26 Feb 2024 23:56:05 -0500 > > > From: Gary Hollis <ghollisjr@HIDDEN> > > > > > > When the point is not at the very end of the iSQL buffer, the > > > process-mark is not kept in a reasonable state if sql-send-string is > > > called. > > > > > > Example to reproduce bug: > > > 1. Open a sql-mode buffer. > > > 2. Connect to a SQL database of choice. > > > 3. Move the point of the iSQL buffer to the top, e.g. with M-< > > > 4. Send good queries via sql-send-string, sql-send-region etc. > > > 5. In iSQL buffer, move point to end, e.g. with M-> > > > 6. Enter a good query. > > > > > > Expected result: The new query successfully sends and sql process > > > returns output. > > > Actual result: Whatever contents had been output from the > > > sql-send-string, sql-send-region etc. will be sent along with the new query. > > > > > > To fix: a call to (end-of-buffer) can be placed within the > > > (save-excursion ...) context before sending any input in the > > > sql-send-string function, e.g. > > > > > > ;; from sql.el with fix for bug added with BUG FIX comment: > > > (defun sql-send-string (str) > > > "Send the string STR to the SQL process." > > > (interactive "sSQL Text: ") > > > > > > (let ((comint-input-sender-no-newline nil) > > > (s (replace-regexp-in-string "[[:space:]\n\r]+\\'" "" str))) > > > (if (sql-buffer-live-p sql-buffer) > > > (progn > > > ;; Ignore the hoping around... > > > (save-excursion > > > ;; Set product context > > > (with-current-buffer sql-buffer > > > (end-of-buffer) ; BUG FIX: correct point before sending input > > > (when sql-debug-send > > > (message ">>SQL> %S" s)) > > > (insert "\n") > > > (comint-set-process-mark) > > > > > > ;; Send the string (trim the trailing whitespace) > > > (sql-input-sender (get-buffer-process (current-buffer)) s) > > > > > > ;; Send a command terminator if we must > > > (sql-send-magic-terminator sql-buffer s sql-send-terminator) > > > > > > (when sql-pop-to-buffer-after-send-region > > > (message "Sent string to buffer %s" sql-buffer)))) > > > > > > ;; Display the sql buffer > > > (sql-display-buffer sql-buffer)) > > > > > > ;; We don't have no stinkin' sql > > > (user-error "No SQL process started")))) > > > > > > > Thanks. > > > > Michael, any comments or suggestions? > > > > > > > > > > > >
X-Loop: help-debbugs@HIDDEN Subject: bug#69420: 29.2; iSQL point/process-mark fix Resent-From: Eli Zaretskii <eliz@HIDDEN> Original-Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> Resent-CC: bug-gnu-emacs@HIDDEN Resent-Date: Sat, 06 Apr 2024 08:57:01 +0000 Resent-Message-ID: <handler.69420.B69420.171239376525837 <at> debbugs.gnu.org> Resent-Sender: help-debbugs@HIDDEN X-GNU-PR-Message: followup 69420 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: michael@HIDDEN Cc: ghollisjr@HIDDEN, 69420 <at> debbugs.gnu.org Received: via spool by 69420-submit <at> debbugs.gnu.org id=B69420.171239376525837 (code B ref 69420); Sat, 06 Apr 2024 08:57:01 +0000 Received: (at 69420) by debbugs.gnu.org; 6 Apr 2024 08:56:05 +0000 Received: from localhost ([127.0.0.1]:38227 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1rt1qG-0006ie-KS for submit <at> debbugs.gnu.org; Sat, 06 Apr 2024 04:56:05 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:50642) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <eliz@HIDDEN>) id 1rt1qE-0006i9-GU for 69420 <at> debbugs.gnu.org; Sat, 06 Apr 2024 04:56:02 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from <eliz@HIDDEN>) id 1rt1q2-0007MM-Nn; Sat, 06 Apr 2024 04:55:50 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-version:References:Subject:In-Reply-To:To:From: Date; bh=pWEGE2I+iE1KDBO43fJSGKJtzdyH9nMa796WHJFSby4=; b=a/22dWO400GOSUAmSTyW YycyFY0DhRrBYGPSJ0LVSaVTC5G+8uXycaALF6T18toRSXbb24AAyKGiP4hgJ5HgI6XjE4OzmcjTp yhGhAX9h26Pnmtpcooy8PUYDRDmn8io1ByxVUFVyN13gx5vL4um+ReOUHBtajbl4Dst4iUx9Gm7aP zuduLkv1CzAqJvoORXaYPWtMvgrh4nqoUC/39PMBnFLcCzi4m6FSvpwdrnAUNzGrjuxs6WX5WWG/d d1LaQ4P6idBmqRCB0S3T6h464Cx9GFZbqa/F4miRCaq7a/GSuCfbpsHvje9Buyre/UAXvjxsUGTtp pwFLpYbnhg/LZQ==; Date: Sat, 06 Apr 2024 11:55:48 +0300 Message-Id: <86cyr250q3.fsf@HIDDEN> From: Eli Zaretskii <eliz@HIDDEN> In-Reply-To: <86frwk2db5.fsf@HIDDEN> (message from Eli Zaretskii on Thu, 21 Mar 2024 10:34:38 +0200) References: <2110e7d1-153c-412a-a0dc-37531a0b6d84@HIDDEN> <864jduuxy1.fsf@HIDDEN> <86le6rye7v.fsf@HIDDEN> <86frwk2db5.fsf@HIDDEN> MIME-version: 1.0 Content-type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -3.3 (---) Ping! Ping! Ping! Michael, are you there? > Cc: ghollisjr@HIDDEN, 69420 <at> debbugs.gnu.org > Date: Thu, 21 Mar 2024 10:34:38 +0200 > From: Eli Zaretskii <eliz@HIDDEN> > > Ping! Ping! Michael, would you please responds and comment on this > issue? > > > Cc: ghollisjr@HIDDEN, 69420 <at> debbugs.gnu.org > > Date: Sat, 09 Mar 2024 10:57:40 +0200 > > From: Eli Zaretskii <eliz@HIDDEN> > > > > Ping! Michael, any comments? > > > > > Cc: 69420 <at> debbugs.gnu.org > > > Date: Tue, 27 Feb 2024 10:13:26 +0200 > > > From: Eli Zaretskii <eliz@HIDDEN> > > > > > > > Date: Mon, 26 Feb 2024 23:56:05 -0500 > > > > From: Gary Hollis <ghollisjr@HIDDEN> > > > > > > > > When the point is not at the very end of the iSQL buffer, the > > > > process-mark is not kept in a reasonable state if sql-send-string is > > > > called. > > > > > > > > Example to reproduce bug: > > > > 1. Open a sql-mode buffer. > > > > 2. Connect to a SQL database of choice. > > > > 3. Move the point of the iSQL buffer to the top, e.g. with M-< > > > > 4. Send good queries via sql-send-string, sql-send-region etc. > > > > 5. In iSQL buffer, move point to end, e.g. with M-> > > > > 6. Enter a good query. > > > > > > > > Expected result: The new query successfully sends and sql process > > > > returns output. > > > > Actual result: Whatever contents had been output from the > > > > sql-send-string, sql-send-region etc. will be sent along with the new query. > > > > > > > > To fix: a call to (end-of-buffer) can be placed within the > > > > (save-excursion ...) context before sending any input in the > > > > sql-send-string function, e.g. > > > > > > > > ;; from sql.el with fix for bug added with BUG FIX comment: > > > > (defun sql-send-string (str) > > > > "Send the string STR to the SQL process." > > > > (interactive "sSQL Text: ") > > > > > > > > (let ((comint-input-sender-no-newline nil) > > > > (s (replace-regexp-in-string "[[:space:]\n\r]+\\'" "" str))) > > > > (if (sql-buffer-live-p sql-buffer) > > > > (progn > > > > ;; Ignore the hoping around... > > > > (save-excursion > > > > ;; Set product context > > > > (with-current-buffer sql-buffer > > > > (end-of-buffer) ; BUG FIX: correct point before sending input > > > > (when sql-debug-send > > > > (message ">>SQL> %S" s)) > > > > (insert "\n") > > > > (comint-set-process-mark) > > > > > > > > ;; Send the string (trim the trailing whitespace) > > > > (sql-input-sender (get-buffer-process (current-buffer)) s) > > > > > > > > ;; Send a command terminator if we must > > > > (sql-send-magic-terminator sql-buffer s sql-send-terminator) > > > > > > > > (when sql-pop-to-buffer-after-send-region > > > > (message "Sent string to buffer %s" sql-buffer)))) > > > > > > > > ;; Display the sql buffer > > > > (sql-display-buffer sql-buffer)) > > > > > > > > ;; We don't have no stinkin' sql > > > > (user-error "No SQL process started")))) > > > > > > > > > > Thanks. > > > > > > Michael, any comments or suggestions? > > > > > > > > > > > > > > > > > > > > > > > >
MIME-Version: 1.0 X-Mailer: MIME-tools 5.505 (Entity 5.505) X-Loop: help-debbugs@HIDDEN From: help-debbugs@HIDDEN (GNU bug Tracking System) To: Eli Zaretskii <eliz@HIDDEN> Subject: bug#69420: closed (29.2; iSQL point/process-mark fix) CC: tracker <at> debbugs.gnu.org Message-ID: <handler.69420.D69420.171343067729290.ackdone <at> debbugs.gnu.org> References: <86h6fzf3qo.fsf@HIDDEN> <2110e7d1-153c-412a-a0dc-37531a0b6d84@HIDDEN> X-Gnu-PR-Message: closed 69420 X-Gnu-PR-Package: emacs Date: Thu, 18 Apr 2024 08:58:10 +0000 Content-Type: multipart/mixed; boundary="----------=_1713430690-29338-0" This is a multi-part message in MIME format... ------------=_1713430690-29338-0 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=utf-8 Your message dated Thu, 18 Apr 2024 11:56:47 +0300 with message-id <86h6fzf3qo.fsf@HIDDEN> and subject line Re: bug#69420: 29.2; iSQL point/process-mark fix has caused the debbugs.gnu.org bug report #69420, regarding 29.2; iSQL point/process-mark fix to be marked as done. (If you believe you have received this mail in error, please contact help-debbugs@HIDDEN) --=20 69420: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D69420 GNU Bug Tracking System Contact help-debbugs@HIDDEN with problems ------------=_1713430690-29338-0 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at submit) by debbugs.gnu.org; 27 Feb 2024 05:03:46 +0000 Received: from localhost ([127.0.0.1]:46574 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1repd3-0006Y7-7p for submit <at> debbugs.gnu.org; Tue, 27 Feb 2024 00:03:46 -0500 Received: from lists.gnu.org ([209.51.188.17]:37944) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <ghollisjr@HIDDEN>) id 1repW9-00069l-SQ for submit <at> debbugs.gnu.org; Mon, 26 Feb 2024 23:56:38 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from <ghollisjr@HIDDEN>) id 1repVj-0006LF-RR for bug-gnu-emacs@HIDDEN; Mon, 26 Feb 2024 23:56:11 -0500 Received: from mail-yw1-x1133.google.com ([2607:f8b0:4864:20::1133]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from <ghollisjr@HIDDEN>) id 1repVh-0004hC-Kp for bug-gnu-emacs@HIDDEN; Mon, 26 Feb 2024 23:56:11 -0500 Received: by mail-yw1-x1133.google.com with SMTP id 00721157ae682-6092387bdd0so4575107b3.3 for <bug-gnu-emacs@HIDDEN>; Mon, 26 Feb 2024 20:56:08 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1709009767; x=1709614567; darn=gnu.org; h=content-transfer-encoding:from:content-language:subject:to :user-agent:mime-version:date:message-id:from:to:cc:subject:date :message-id:reply-to; bh=cKF4AdeuzY+J1AcLQk1F1CT4G4K6L3nx9zKzVuxShus=; b=i2IrybCM/7EMvZQuR2yUiAVvFSMhLHFNytKS5ZHjd/TdossXPu+qt8XiyD8cs/sVxZ 1JHrRrDTc53dRZs7Ixvo8sgqV4gEzcGkY9Qsn8lnK8FsvdjG3lw7penPSO4ZS1D7Bjzo ONtHakTIyaYM0Sbo3ua05YQsm0VrWx7HPTasO0OQj6LtmTSXTQXdIAQRbRW0jdpGLTno HotB615wqG6hDOP2+TPW6av/E9X3oyBWxC9Fs7ENzeIzSsfjxS+FMGGrgivDe682oHzr 9VPeeYSt1yvNO/qTXNAdqls1BiK3frULzlGgAza/58rmLWAxKw14nZGBRnOm/B+O50GH XI+w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1709009767; x=1709614567; h=content-transfer-encoding:from:content-language:subject:to :user-agent:mime-version:date:message-id:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=cKF4AdeuzY+J1AcLQk1F1CT4G4K6L3nx9zKzVuxShus=; b=rQbg5QK9xHxYvxdTuu+NfX48DuYo8VI3EjanRbZhSE3I4Qd2XCuLO+ZlCMn7bU81st GDaaADOyBBN12xLiMvCh91DxbtJvGoNOBjZUetywSivGx6albAgWFy6Dfw2Vue81ykvf CWTZIHQWX0oDgesxKT+EZ1Vw9/WzUsxVYQcTehQw/y2OV7IkUPXCcSGgdnqUrFu/1k0Q AFlX+2KDUB/pDCTyCgNE0+Gx+4ceHB2/V1/bcLr0kKkl7mTMDZcvgoIpTONIqQC6BWVV aJC9depo4vf7s0o0oz+UN5DMRM1TcmmSE7nrHaMMtOTtGnxemlcARBTSpf0fiIaB67Tu bfcA== X-Gm-Message-State: AOJu0YzoPV08POYuij4cYGaRAKWBoWltQ5Hm90/0GRPzKdQwSPgrKeSQ xJ9tBN3WOgI5Wl+LH/A0kt3OLSIV87tPwpq1AO+y1O6nsKvzSzoX5tsXG6jX X-Google-Smtp-Source: AGHT+IGF972p/wZPw3nFOuyFm7bN7Ck1W7aFIdP17BM2Dl+2jF9MnMxbayiGbAD7iRZd9Kt9/Nl16A== X-Received: by 2002:a05:690c:9d:b0:607:9dda:676c with SMTP id be29-20020a05690c009d00b006079dda676cmr1392372ywb.18.1709009767263; Mon, 26 Feb 2024 20:56:07 -0800 (PST) Received: from [192.168.1.3] (173-093-201-060.res.spectrum.com. [173.93.201.60]) by smtp.gmail.com with ESMTPSA id x21-20020a0dd515000000b00607fab8965esm1572425ywd.32.2024.02.26.20.56.06 for <bug-gnu-emacs@HIDDEN> (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 26 Feb 2024 20:56:06 -0800 (PST) Message-ID: <2110e7d1-153c-412a-a0dc-37531a0b6d84@HIDDEN> Date: Mon, 26 Feb 2024 23:56:05 -0500 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird To: bug-gnu-emacs@HIDDEN Subject: 29.2; iSQL point/process-mark fix Content-Language: en-US From: Gary Hollis <ghollisjr@HIDDEN> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Received-SPF: pass client-ip=2607:f8b0:4864:20::1133; envelope-from=ghollisjr@HIDDEN; helo=mail-yw1-x1133.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: -1.3 (-) X-Debbugs-Envelope-To: submit X-Mailman-Approved-At: Tue, 27 Feb 2024 00:03:43 -0500 X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -2.3 (--) When the point is not at the very end of the iSQL buffer, the process-mark is not kept in a reasonable state if sql-send-string is called. Example to reproduce bug: 1. Open a sql-mode buffer. 2. Connect to a SQL database of choice. 3. Move the point of the iSQL buffer to the top, e.g. with M-< 4. Send good queries via sql-send-string, sql-send-region etc. 5. In iSQL buffer, move point to end, e.g. with M-> 6. Enter a good query. Expected result: The new query successfully sends and sql process returns output. Actual result: Whatever contents had been output from the sql-send-string, sql-send-region etc. will be sent along with the new query. To fix: a call to (end-of-buffer) can be placed within the (save-excursion ...) context before sending any input in the sql-send-string function, e.g. ;; from sql.el with fix for bug added with BUG FIX comment: (defun sql-send-string (str) "Send the string STR to the SQL process." (interactive "sSQL Text: ") (let ((comint-input-sender-no-newline nil) (s (replace-regexp-in-string "[[:space:]\n\r]+\\'" "" str))) (if (sql-buffer-live-p sql-buffer) (progn ;; Ignore the hoping around... (save-excursion ;; Set product context (with-current-buffer sql-buffer (end-of-buffer) ; BUG FIX: correct point before sending input (when sql-debug-send (message ">>SQL> %S" s)) (insert "\n") (comint-set-process-mark) ;; Send the string (trim the trailing whitespace) (sql-input-sender (get-buffer-process (current-buffer)) s) ;; Send a command terminator if we must (sql-send-magic-terminator sql-buffer s sql-send-terminator) (when sql-pop-to-buffer-after-send-region (message "Sent string to buffer %s" sql-buffer)))) ;; Display the sql buffer (sql-display-buffer sql-buffer)) ;; We don't have no stinkin' sql (user-error "No SQL process started")))) In GNU Emacs 29.2 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.24.40, cairo version 1.18.0) Windowing system distributor 'The X.Org Foundation', version 11.0.12101011 System Description: Arch Linux Configured using: 'configure --sysconfdir=/etc --prefix=/usr --libexecdir=/usr/lib --with-tree-sitter --localstatedir=/var --with-cairo --disable-build-details --with-harfbuzz --with-libsystemd --with-modules --with-x-toolkit=gtk3 'CFLAGS=-march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security -fstack-clash-protection -fcf-protection -g -ffile-prefix-map=/build/emacs/src=/usr/src/debug/emacs -flto=auto' 'LDFLAGS=-Wl,-O1,--sort-common,--as-needed,-z,relro,-z,now -flto=auto'' Configured features: ACL CAIRO DBUS FREETYPE GIF GLIB GMP GNUTLS GPM GSETTINGS HARFBUZZ JPEG JSON LCMS2 LIBOTF LIBSYSTEMD LIBXML2 M17N_FLT MODULES NOTIFY INOTIFY PDUMPER PNG RSVG SECCOMP SOUND SQLITE3 THREADS TIFF TOOLKIT_SCROLL_BARS TREE_SITTER WEBP X11 XDBE XIM XINPUT2 XPM GTK3 ZLIB Important settings: value of $LANG: en_US.UTF-8 value of $XMODIFIERS: @im=ibus locale-coding-system: utf-8-unix Major mode: Lisp Interaction Minor modes in effect: recentf-mode: t server-mode: t form-feed-mode: t shell-dirtrack-mode: t pyvenv-mode: t ivy-mode: t delete-selection-mode: t projectile-mode: t global-auto-revert-mode: t global-company-mode: t company-mode: t global-display-line-numbers-mode: t display-line-numbers-mode: t tooltip-mode: t global-eldoc-mode: t eldoc-mode: t show-paren-mode: t electric-indent-mode: t mouse-wheel-mode: t tool-bar-mode: t prettify-symbols-mode: t menu-bar-mode: t file-name-shadow-mode: t global-font-lock-mode: t font-lock-mode: t blink-cursor-mode: t column-number-mode: t line-number-mode: t transient-mark-mode: t auto-composition-mode: t auto-encryption-mode: t auto-compression-mode: t Load-path shadows: ~/.emacs.d/lisp/glsl-mode hides /home/ghollisjr/.emacs.d/elpa/glsl-mode-20210808.1945/glsl-mode ~/.emacs.d/lisp/popup hides /home/ghollisjr/.emacs.d/elpa/popup-20221231.1634/popup /home/ghollisjr/src/slime/slime-tests hides /home/ghollisjr/.emacs.d/elpa/slime-20230707.1938/slime-tests /home/ghollisjr/src/slime/slime hides /home/ghollisjr/.emacs.d/elpa/slime-20230707.1938/slime /home/ghollisjr/src/slime/slime-autoloads hides /home/ghollisjr/.emacs.d/elpa/slime-20230707.1938/slime-autoloads /home/ghollisjr/.emacs.d/elpa/maxima-20230529.1658/maxima-font-lock hides /usr/share/emacs/site-lisp/maxima/maxima-font-lock /home/ghollisjr/.emacs.d/elpa/maxima-20230529.1658/maxima hides /usr/share/emacs/site-lisp/maxima/maxima /home/ghollisjr/.emacs.d/elpa/csharp-mode-20221126.2005/csharp-mode hides /usr/share/emacs/29.2/lisp/progmodes/csharp-mode Features: (shadow sort mail-extr emacsbug message yank-media rfc822 mml mml-sec epa epg rfc6068 epg-config mm-decode mm-bodies mm-encode mail-parse rfc2231 mailabbrev gmm-utils mailheader sendmail rfc2047 rfc2045 ietf-drums goto-addr flyspell ispell jka-compr apropos face-remap misearch multi-isearch thai-util thai-word mule-util lao-util vc-hg vc-git vc-bzr vc-src vc-sccs vc-svn vc-cvs vc-rcs log-view pcvs-util vc vc-dispatcher enriched sql-indent sql-datum sql view recentf tree-widget bookmark server form-feed company-oddmuse company-keywords make-mode company-etags company-gtags company-dabbrev-code company-dabbrev company-files company-clang company-cmake company-semantic company-template company-bbdb use-package-core bash-completion shell pcomplete sh-script executable prettify-math-mode pgformatter ucsf-evan ffap multiple-cursors mc-separate-operations rectangular-region-mode mc-mark-pop mc-edit-lines mc-hide-unmatched-lines-mode mc-mark-more mc-cycle-cursors multiple-cursors-core rect yasnippet cl-extra highlight-indentation flymake-proc flymake warnings company-capf help-fns radix-tree help-mode elpy elpy-rpc pyvenv eshell esh-cmd esh-ext esh-opt esh-proc esh-io esh-arg esh-module esh-groups esh-util elpy-shell elpy-profile elpy-django s elpy-refactor diff-mode ido hideshow files-x cus-edit cus-load ivy delsel ivy-faces ivy-overlay colir projectile skeleton ibuf-macs find-dired dired dired-loaddefs lisp-mnt grep ibuf-ext ibuffer ibuffer-loaddefs opencl-mode align find-file glsl-mode cmake-mode rst qml-mode js c-ts-common cc-mode cc-fonts cc-guess cc-menus cc-cmds cc-styles cc-align cc-engine cc-vars cc-defs css-mode smie sgml-mode facemenu imenu eww xdg url-queue shr pixel-fill kinsoku url-file svg xml dom puny mm-url gnus nnheader gnus-util time-date mail-utils range wid-edit mm-util mail-prsvr color web-mode disp-table autorevert filenotify python-black reformatter python compat treesit dash slime-company derived company pcase slime-fancy slime-indentation slime-cl-indent cl-indent slime-trace-dialog slime-fontifying-fu slime-package-fu slime-references slime-compiler-notes-tree advice slime-scratch slime-presentations bridge slime-macrostep macrostep slime-mdot-fu slime-enclosing-context slime-fuzzy slime-fancy-trace slime-fancy-inspector slime-c-p-c slime-editing-commands slime-autodoc slime-repl slime-parse slime easy-mmode compile text-property-search etags fileloop generator xref project arc-mode archive-mode noutline outline icons pp comint ansi-osc ansi-color ring hyperspec thingatpt display-line-numbers finder-inf ede/auto eieio-base ein-autoloads deferred-autoloads anaphora-autoloads rx polymode-autoloads simple-httpd-autoloads slime-autoloads websocket-autoloads with-editor-autoloads info compat-autoloads zmq-autoloads package browse-url url url-proxy url-privacy url-expand url-methods url-history url-cookie generate-lisp-file url-domsuf url-util mailcap url-handlers url-parse auth-source cl-seq eieio eieio-core cl-macs password-cache json subr-x map byte-opt gv bytecomp byte-compile url-vars cl-loaddefs cl-lib rmc iso-transl tooltip cconv eldoc paren electric uniquify ediff-hook vc-hooks lisp-float-type elisp-mode 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 lisp-mode prog-mode register page tab-bar menu-bar rfn-eshadow isearch easymenu timer select scroll-bar mouse jit-lock font-lock syntax font-core term/tty-colors frame minibuffer nadvice seq simple cl-generic indonesian philippine 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 emoji-zwj charscript charprop case-table epa-hook jka-cmpr-hook help abbrev obarray oclosure cl-preloaded button loaddefs theme-loaddefs faces cus-face macroexp files window text-properties overlay sha1 md5 base64 format env code-pages mule custom widget keymap hashtable-print-readable backquote threads dbusbind inotify lcms2 dynamic-setting system-font-setting font-render-setting cairo move-toolbar gtk x-toolkit xinput2 x multi-tty make-network-process emacs) Memory information: ((conses 16 653922 33278) (symbols 48 36133 0) (strings 32 123994 8934) (string-bytes 1 4062606) (vectors 16 49840) (vector-slots 8 650455 27338) (floats 8 292 333) (intervals 56 8562 0) (buffers 984 16)) ------------=_1713430690-29338-0 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at 69420-done) by debbugs.gnu.org; 18 Apr 2024 08:57:57 +0000 Received: from localhost ([127.0.0.1]:51133 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1rxNaY-0007bZ-63 for submit <at> debbugs.gnu.org; Thu, 18 Apr 2024 04:57:54 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:52424) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <eliz@HIDDEN>) id 1rxNaP-0007Zv-AW for 69420-done <at> debbugs.gnu.org; Thu, 18 Apr 2024 04:57:45 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from <eliz@HIDDEN>) id 1rxNa5-0007sw-5N; Thu, 18 Apr 2024 04:57:22 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=mvj0nr8DVAPDDGWCYWsQ0FgIu5uAAxG2nbPzLWj9SEU=; b=lwrh+lPM8+/f 3EIAUx+22MprfTtFMWlqji41H0nsSKHrG9JFVRrZea3IQborXOXRJocdDtVszucQL4DVRmiJgxrqu bTAVmba92nPYT4yeHVAsu8DfKtXWGmLWRfIhkyqFEC8/EJ5M9AAdsThIKR395L+QgF78xm8s/st9k 0K3Zz9iz2GGjRa0pRgCuC/H9wCjGU+mMubfKbUsxzDpcr6KyOHbmKZI348bHgsBt7jS82ECRPrhWC PCaTk8Rl901rCgHRDl20G4IKa6KfJWZF1/Jsf49kFAhJsmeSdYxErvKOxhbEpIdHjYPV4pKxmhjuw XE3UhwdVCh9rFE02wlpjkA==; Date: Thu, 18 Apr 2024 11:56:47 +0300 Message-Id: <86h6fzf3qo.fsf@HIDDEN> From: Eli Zaretskii <eliz@HIDDEN> To: ghollisjr@HIDDEN In-Reply-To: <86cyr250q3.fsf@HIDDEN> (message from Eli Zaretskii on Sat, 06 Apr 2024 11:55:48 +0300) Subject: Re: bug#69420: 29.2; iSQL point/process-mark fix References: <2110e7d1-153c-412a-a0dc-37531a0b6d84@HIDDEN> <864jduuxy1.fsf@HIDDEN> <86le6rye7v.fsf@HIDDEN> <86frwk2db5.fsf@HIDDEN> <86cyr250q3.fsf@HIDDEN> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 69420-done Cc: 69420-done <at> debbugs.gnu.org, michael@HIDDEN X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -3.3 (---) > Cc: ghollisjr@HIDDEN, 69420 <at> debbugs.gnu.org > Date: Sat, 06 Apr 2024 11:55:48 +0300 > From: Eli Zaretskii <eliz@HIDDEN> > > Ping! Ping! Ping! Michael, are you there? No response or further comments in almost 2 months, so I have now installed the proposed change (except that I used goto-char instead of end-of-buffer, which is for interactive invocations only) on the master branch, and I'm therefore boldly closing this bug. ------------=_1713430690-29338-0--
MIME-Version: 1.0 X-Mailer: MIME-tools 5.505 (Entity 5.505) X-Loop: help-debbugs@HIDDEN From: help-debbugs@HIDDEN (GNU bug Tracking System) To: Gary Hollis <ghollisjr@HIDDEN> Subject: bug#69420: closed (Re: bug#69420: 29.2; iSQL point/process-mark fix) Message-ID: <handler.69420.D69420.171343067729290.notifdone <at> debbugs.gnu.org> References: <86h6fzf3qo.fsf@HIDDEN> <2110e7d1-153c-412a-a0dc-37531a0b6d84@HIDDEN> X-Gnu-PR-Message: they-closed 69420 X-Gnu-PR-Package: emacs Reply-To: 69420 <at> debbugs.gnu.org Date: Thu, 18 Apr 2024 08:58:11 +0000 Content-Type: multipart/mixed; boundary="----------=_1713430691-29338-1" This is a multi-part message in MIME format... ------------=_1713430691-29338-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Your bug report #69420: 29.2; iSQL point/process-mark fix which was filed against the emacs package, has been closed. The explanation is attached below, along with your original report. If you require more details, please reply to 69420 <at> debbugs.gnu.org. --=20 69420: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D69420 GNU Bug Tracking System Contact help-debbugs@HIDDEN with problems ------------=_1713430691-29338-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at 69420-done) by debbugs.gnu.org; 18 Apr 2024 08:57:57 +0000 Received: from localhost ([127.0.0.1]:51133 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1rxNaY-0007bZ-63 for submit <at> debbugs.gnu.org; Thu, 18 Apr 2024 04:57:54 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:52424) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <eliz@HIDDEN>) id 1rxNaP-0007Zv-AW for 69420-done <at> debbugs.gnu.org; Thu, 18 Apr 2024 04:57:45 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from <eliz@HIDDEN>) id 1rxNa5-0007sw-5N; Thu, 18 Apr 2024 04:57:22 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=mvj0nr8DVAPDDGWCYWsQ0FgIu5uAAxG2nbPzLWj9SEU=; b=lwrh+lPM8+/f 3EIAUx+22MprfTtFMWlqji41H0nsSKHrG9JFVRrZea3IQborXOXRJocdDtVszucQL4DVRmiJgxrqu bTAVmba92nPYT4yeHVAsu8DfKtXWGmLWRfIhkyqFEC8/EJ5M9AAdsThIKR395L+QgF78xm8s/st9k 0K3Zz9iz2GGjRa0pRgCuC/H9wCjGU+mMubfKbUsxzDpcr6KyOHbmKZI348bHgsBt7jS82ECRPrhWC PCaTk8Rl901rCgHRDl20G4IKa6KfJWZF1/Jsf49kFAhJsmeSdYxErvKOxhbEpIdHjYPV4pKxmhjuw XE3UhwdVCh9rFE02wlpjkA==; Date: Thu, 18 Apr 2024 11:56:47 +0300 Message-Id: <86h6fzf3qo.fsf@HIDDEN> From: Eli Zaretskii <eliz@HIDDEN> To: ghollisjr@HIDDEN In-Reply-To: <86cyr250q3.fsf@HIDDEN> (message from Eli Zaretskii on Sat, 06 Apr 2024 11:55:48 +0300) Subject: Re: bug#69420: 29.2; iSQL point/process-mark fix References: <2110e7d1-153c-412a-a0dc-37531a0b6d84@HIDDEN> <864jduuxy1.fsf@HIDDEN> <86le6rye7v.fsf@HIDDEN> <86frwk2db5.fsf@HIDDEN> <86cyr250q3.fsf@HIDDEN> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 69420-done Cc: 69420-done <at> debbugs.gnu.org, michael@HIDDEN X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -3.3 (---) > Cc: ghollisjr@HIDDEN, 69420 <at> debbugs.gnu.org > Date: Sat, 06 Apr 2024 11:55:48 +0300 > From: Eli Zaretskii <eliz@HIDDEN> > > Ping! Ping! Ping! Michael, are you there? No response or further comments in almost 2 months, so I have now installed the proposed change (except that I used goto-char instead of end-of-buffer, which is for interactive invocations only) on the master branch, and I'm therefore boldly closing this bug. ------------=_1713430691-29338-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at submit) by debbugs.gnu.org; 27 Feb 2024 05:03:46 +0000 Received: from localhost ([127.0.0.1]:46574 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1repd3-0006Y7-7p for submit <at> debbugs.gnu.org; Tue, 27 Feb 2024 00:03:46 -0500 Received: from lists.gnu.org ([209.51.188.17]:37944) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <ghollisjr@HIDDEN>) id 1repW9-00069l-SQ for submit <at> debbugs.gnu.org; Mon, 26 Feb 2024 23:56:38 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from <ghollisjr@HIDDEN>) id 1repVj-0006LF-RR for bug-gnu-emacs@HIDDEN; Mon, 26 Feb 2024 23:56:11 -0500 Received: from mail-yw1-x1133.google.com ([2607:f8b0:4864:20::1133]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from <ghollisjr@HIDDEN>) id 1repVh-0004hC-Kp for bug-gnu-emacs@HIDDEN; Mon, 26 Feb 2024 23:56:11 -0500 Received: by mail-yw1-x1133.google.com with SMTP id 00721157ae682-6092387bdd0so4575107b3.3 for <bug-gnu-emacs@HIDDEN>; Mon, 26 Feb 2024 20:56:08 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1709009767; x=1709614567; darn=gnu.org; h=content-transfer-encoding:from:content-language:subject:to :user-agent:mime-version:date:message-id:from:to:cc:subject:date :message-id:reply-to; bh=cKF4AdeuzY+J1AcLQk1F1CT4G4K6L3nx9zKzVuxShus=; b=i2IrybCM/7EMvZQuR2yUiAVvFSMhLHFNytKS5ZHjd/TdossXPu+qt8XiyD8cs/sVxZ 1JHrRrDTc53dRZs7Ixvo8sgqV4gEzcGkY9Qsn8lnK8FsvdjG3lw7penPSO4ZS1D7Bjzo ONtHakTIyaYM0Sbo3ua05YQsm0VrWx7HPTasO0OQj6LtmTSXTQXdIAQRbRW0jdpGLTno HotB615wqG6hDOP2+TPW6av/E9X3oyBWxC9Fs7ENzeIzSsfjxS+FMGGrgivDe682oHzr 9VPeeYSt1yvNO/qTXNAdqls1BiK3frULzlGgAza/58rmLWAxKw14nZGBRnOm/B+O50GH XI+w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1709009767; x=1709614567; h=content-transfer-encoding:from:content-language:subject:to :user-agent:mime-version:date:message-id:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=cKF4AdeuzY+J1AcLQk1F1CT4G4K6L3nx9zKzVuxShus=; b=rQbg5QK9xHxYvxdTuu+NfX48DuYo8VI3EjanRbZhSE3I4Qd2XCuLO+ZlCMn7bU81st GDaaADOyBBN12xLiMvCh91DxbtJvGoNOBjZUetywSivGx6albAgWFy6Dfw2Vue81ykvf CWTZIHQWX0oDgesxKT+EZ1Vw9/WzUsxVYQcTehQw/y2OV7IkUPXCcSGgdnqUrFu/1k0Q AFlX+2KDUB/pDCTyCgNE0+Gx+4ceHB2/V1/bcLr0kKkl7mTMDZcvgoIpTONIqQC6BWVV aJC9depo4vf7s0o0oz+UN5DMRM1TcmmSE7nrHaMMtOTtGnxemlcARBTSpf0fiIaB67Tu bfcA== X-Gm-Message-State: AOJu0YzoPV08POYuij4cYGaRAKWBoWltQ5Hm90/0GRPzKdQwSPgrKeSQ xJ9tBN3WOgI5Wl+LH/A0kt3OLSIV87tPwpq1AO+y1O6nsKvzSzoX5tsXG6jX X-Google-Smtp-Source: AGHT+IGF972p/wZPw3nFOuyFm7bN7Ck1W7aFIdP17BM2Dl+2jF9MnMxbayiGbAD7iRZd9Kt9/Nl16A== X-Received: by 2002:a05:690c:9d:b0:607:9dda:676c with SMTP id be29-20020a05690c009d00b006079dda676cmr1392372ywb.18.1709009767263; Mon, 26 Feb 2024 20:56:07 -0800 (PST) Received: from [192.168.1.3] (173-093-201-060.res.spectrum.com. [173.93.201.60]) by smtp.gmail.com with ESMTPSA id x21-20020a0dd515000000b00607fab8965esm1572425ywd.32.2024.02.26.20.56.06 for <bug-gnu-emacs@HIDDEN> (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 26 Feb 2024 20:56:06 -0800 (PST) Message-ID: <2110e7d1-153c-412a-a0dc-37531a0b6d84@HIDDEN> Date: Mon, 26 Feb 2024 23:56:05 -0500 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird To: bug-gnu-emacs@HIDDEN Subject: 29.2; iSQL point/process-mark fix Content-Language: en-US From: Gary Hollis <ghollisjr@HIDDEN> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Received-SPF: pass client-ip=2607:f8b0:4864:20::1133; envelope-from=ghollisjr@HIDDEN; helo=mail-yw1-x1133.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: -1.3 (-) X-Debbugs-Envelope-To: submit X-Mailman-Approved-At: Tue, 27 Feb 2024 00:03:43 -0500 X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -2.3 (--) When the point is not at the very end of the iSQL buffer, the process-mark is not kept in a reasonable state if sql-send-string is called. Example to reproduce bug: 1. Open a sql-mode buffer. 2. Connect to a SQL database of choice. 3. Move the point of the iSQL buffer to the top, e.g. with M-< 4. Send good queries via sql-send-string, sql-send-region etc. 5. In iSQL buffer, move point to end, e.g. with M-> 6. Enter a good query. Expected result: The new query successfully sends and sql process returns output. Actual result: Whatever contents had been output from the sql-send-string, sql-send-region etc. will be sent along with the new query. To fix: a call to (end-of-buffer) can be placed within the (save-excursion ...) context before sending any input in the sql-send-string function, e.g. ;; from sql.el with fix for bug added with BUG FIX comment: (defun sql-send-string (str) "Send the string STR to the SQL process." (interactive "sSQL Text: ") (let ((comint-input-sender-no-newline nil) (s (replace-regexp-in-string "[[:space:]\n\r]+\\'" "" str))) (if (sql-buffer-live-p sql-buffer) (progn ;; Ignore the hoping around... (save-excursion ;; Set product context (with-current-buffer sql-buffer (end-of-buffer) ; BUG FIX: correct point before sending input (when sql-debug-send (message ">>SQL> %S" s)) (insert "\n") (comint-set-process-mark) ;; Send the string (trim the trailing whitespace) (sql-input-sender (get-buffer-process (current-buffer)) s) ;; Send a command terminator if we must (sql-send-magic-terminator sql-buffer s sql-send-terminator) (when sql-pop-to-buffer-after-send-region (message "Sent string to buffer %s" sql-buffer)))) ;; Display the sql buffer (sql-display-buffer sql-buffer)) ;; We don't have no stinkin' sql (user-error "No SQL process started")))) In GNU Emacs 29.2 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.24.40, cairo version 1.18.0) Windowing system distributor 'The X.Org Foundation', version 11.0.12101011 System Description: Arch Linux Configured using: 'configure --sysconfdir=/etc --prefix=/usr --libexecdir=/usr/lib --with-tree-sitter --localstatedir=/var --with-cairo --disable-build-details --with-harfbuzz --with-libsystemd --with-modules --with-x-toolkit=gtk3 'CFLAGS=-march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security -fstack-clash-protection -fcf-protection -g -ffile-prefix-map=/build/emacs/src=/usr/src/debug/emacs -flto=auto' 'LDFLAGS=-Wl,-O1,--sort-common,--as-needed,-z,relro,-z,now -flto=auto'' Configured features: ACL CAIRO DBUS FREETYPE GIF GLIB GMP GNUTLS GPM GSETTINGS HARFBUZZ JPEG JSON LCMS2 LIBOTF LIBSYSTEMD LIBXML2 M17N_FLT MODULES NOTIFY INOTIFY PDUMPER PNG RSVG SECCOMP SOUND SQLITE3 THREADS TIFF TOOLKIT_SCROLL_BARS TREE_SITTER WEBP X11 XDBE XIM XINPUT2 XPM GTK3 ZLIB Important settings: value of $LANG: en_US.UTF-8 value of $XMODIFIERS: @im=ibus locale-coding-system: utf-8-unix Major mode: Lisp Interaction Minor modes in effect: recentf-mode: t server-mode: t form-feed-mode: t shell-dirtrack-mode: t pyvenv-mode: t ivy-mode: t delete-selection-mode: t projectile-mode: t global-auto-revert-mode: t global-company-mode: t company-mode: t global-display-line-numbers-mode: t display-line-numbers-mode: t tooltip-mode: t global-eldoc-mode: t eldoc-mode: t show-paren-mode: t electric-indent-mode: t mouse-wheel-mode: t tool-bar-mode: t prettify-symbols-mode: t menu-bar-mode: t file-name-shadow-mode: t global-font-lock-mode: t font-lock-mode: t blink-cursor-mode: t column-number-mode: t line-number-mode: t transient-mark-mode: t auto-composition-mode: t auto-encryption-mode: t auto-compression-mode: t Load-path shadows: ~/.emacs.d/lisp/glsl-mode hides /home/ghollisjr/.emacs.d/elpa/glsl-mode-20210808.1945/glsl-mode ~/.emacs.d/lisp/popup hides /home/ghollisjr/.emacs.d/elpa/popup-20221231.1634/popup /home/ghollisjr/src/slime/slime-tests hides /home/ghollisjr/.emacs.d/elpa/slime-20230707.1938/slime-tests /home/ghollisjr/src/slime/slime hides /home/ghollisjr/.emacs.d/elpa/slime-20230707.1938/slime /home/ghollisjr/src/slime/slime-autoloads hides /home/ghollisjr/.emacs.d/elpa/slime-20230707.1938/slime-autoloads /home/ghollisjr/.emacs.d/elpa/maxima-20230529.1658/maxima-font-lock hides /usr/share/emacs/site-lisp/maxima/maxima-font-lock /home/ghollisjr/.emacs.d/elpa/maxima-20230529.1658/maxima hides /usr/share/emacs/site-lisp/maxima/maxima /home/ghollisjr/.emacs.d/elpa/csharp-mode-20221126.2005/csharp-mode hides /usr/share/emacs/29.2/lisp/progmodes/csharp-mode Features: (shadow sort mail-extr emacsbug message yank-media rfc822 mml mml-sec epa epg rfc6068 epg-config mm-decode mm-bodies mm-encode mail-parse rfc2231 mailabbrev gmm-utils mailheader sendmail rfc2047 rfc2045 ietf-drums goto-addr flyspell ispell jka-compr apropos face-remap misearch multi-isearch thai-util thai-word mule-util lao-util vc-hg vc-git vc-bzr vc-src vc-sccs vc-svn vc-cvs vc-rcs log-view pcvs-util vc vc-dispatcher enriched sql-indent sql-datum sql view recentf tree-widget bookmark server form-feed company-oddmuse company-keywords make-mode company-etags company-gtags company-dabbrev-code company-dabbrev company-files company-clang company-cmake company-semantic company-template company-bbdb use-package-core bash-completion shell pcomplete sh-script executable prettify-math-mode pgformatter ucsf-evan ffap multiple-cursors mc-separate-operations rectangular-region-mode mc-mark-pop mc-edit-lines mc-hide-unmatched-lines-mode mc-mark-more mc-cycle-cursors multiple-cursors-core rect yasnippet cl-extra highlight-indentation flymake-proc flymake warnings company-capf help-fns radix-tree help-mode elpy elpy-rpc pyvenv eshell esh-cmd esh-ext esh-opt esh-proc esh-io esh-arg esh-module esh-groups esh-util elpy-shell elpy-profile elpy-django s elpy-refactor diff-mode ido hideshow files-x cus-edit cus-load ivy delsel ivy-faces ivy-overlay colir projectile skeleton ibuf-macs find-dired dired dired-loaddefs lisp-mnt grep ibuf-ext ibuffer ibuffer-loaddefs opencl-mode align find-file glsl-mode cmake-mode rst qml-mode js c-ts-common cc-mode cc-fonts cc-guess cc-menus cc-cmds cc-styles cc-align cc-engine cc-vars cc-defs css-mode smie sgml-mode facemenu imenu eww xdg url-queue shr pixel-fill kinsoku url-file svg xml dom puny mm-url gnus nnheader gnus-util time-date mail-utils range wid-edit mm-util mail-prsvr color web-mode disp-table autorevert filenotify python-black reformatter python compat treesit dash slime-company derived company pcase slime-fancy slime-indentation slime-cl-indent cl-indent slime-trace-dialog slime-fontifying-fu slime-package-fu slime-references slime-compiler-notes-tree advice slime-scratch slime-presentations bridge slime-macrostep macrostep slime-mdot-fu slime-enclosing-context slime-fuzzy slime-fancy-trace slime-fancy-inspector slime-c-p-c slime-editing-commands slime-autodoc slime-repl slime-parse slime easy-mmode compile text-property-search etags fileloop generator xref project arc-mode archive-mode noutline outline icons pp comint ansi-osc ansi-color ring hyperspec thingatpt display-line-numbers finder-inf ede/auto eieio-base ein-autoloads deferred-autoloads anaphora-autoloads rx polymode-autoloads simple-httpd-autoloads slime-autoloads websocket-autoloads with-editor-autoloads info compat-autoloads zmq-autoloads package browse-url url url-proxy url-privacy url-expand url-methods url-history url-cookie generate-lisp-file url-domsuf url-util mailcap url-handlers url-parse auth-source cl-seq eieio eieio-core cl-macs password-cache json subr-x map byte-opt gv bytecomp byte-compile url-vars cl-loaddefs cl-lib rmc iso-transl tooltip cconv eldoc paren electric uniquify ediff-hook vc-hooks lisp-float-type elisp-mode 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 lisp-mode prog-mode register page tab-bar menu-bar rfn-eshadow isearch easymenu timer select scroll-bar mouse jit-lock font-lock syntax font-core term/tty-colors frame minibuffer nadvice seq simple cl-generic indonesian philippine 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 emoji-zwj charscript charprop case-table epa-hook jka-cmpr-hook help abbrev obarray oclosure cl-preloaded button loaddefs theme-loaddefs faces cus-face macroexp files window text-properties overlay sha1 md5 base64 format env code-pages mule custom widget keymap hashtable-print-readable backquote threads dbusbind inotify lcms2 dynamic-setting system-font-setting font-render-setting cairo move-toolbar gtk x-toolkit xinput2 x multi-tty make-network-process emacs) Memory information: ((conses 16 653922 33278) (symbols 48 36133 0) (strings 32 123994 8934) (string-bytes 1 4062606) (vectors 16 49840) (vector-slots 8 650455 27338) (floats 8 292 333) (intervals 56 8562 0) (buffers 984 16)) ------------=_1713430691-29338-1--
X-Loop: help-debbugs@HIDDEN Subject: bug#69420: 29.2; iSQL point/process-mark fix Resent-From: Michael Mauger <mmauger@HIDDEN> Original-Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> Resent-CC: bug-gnu-emacs@HIDDEN Resent-Date: Sun, 21 Apr 2024 21:34:05 +0000 Resent-Message-ID: <handler.69420.B69420.17137352333659 <at> debbugs.gnu.org> Resent-Sender: help-debbugs@HIDDEN X-GNU-PR-Message: followup 69420 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Eli Zaretskii <eliz@HIDDEN> Cc: ghollisjr@HIDDEN, michael@HIDDEN, 69420 <at> debbugs.gnu.org Received: via spool by 69420-submit <at> debbugs.gnu.org id=B69420.17137352333659 (code B ref 69420); Sun, 21 Apr 2024 21:34:05 +0000 Received: (at 69420) by debbugs.gnu.org; 21 Apr 2024 21:33:53 +0000 Received: from localhost ([127.0.0.1]:44994 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1ryeoq-0000wr-KN for submit <at> debbugs.gnu.org; Sun, 21 Apr 2024 17:33:53 -0400 Received: from mail-40131.protonmail.ch ([185.70.40.131]:64687) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <mmauger@HIDDEN>) id 1ryeom-0000vd-Fp for 69420 <at> debbugs.gnu.org; Sun, 21 Apr 2024 17:33:50 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=protonmail.com; s=protonmail3; t=1713735206; x=1713994406; bh=AM2W4CbdDGYzzr1qnZbqTuWKgDxmzAjfquJQ5Dwz1FQ=; h=Date:To:From:Cc:Subject:Message-ID:In-Reply-To:References: Feedback-ID:From:To:Cc:Date:Subject:Reply-To:Feedback-ID: Message-ID:BIMI-Selector; b=Rkyj+5O0Rqy42lW10QGrBsLL4DZADOh1HENMsUbfo+AmVc/OaVBYeWTOqxh7T/O3k ZaiSuMlbAxYruy2AItz0vV3BvzDYNzqFaFRY3W/HNTZywlS46C9RhA+sSDBeaMXczi 8naafRUGKTQ2nWtDVamARlMSRzUDie9l/Qn8vdVJ9MKoN71SgpIWbluMJDxopZ0ZHo JA1AQsPuCwxB6R+s/7UCAHbYZAcNBDKE7NmioRgmv7WYbR5KHrH/xlAqTVh1laZkGl GFJLKhQbn6qmgWuE1dXf5zsLDpyomtUjUnp8gsdwCCdIOzf6Sx4HStZRaCdn5hpigB pp+J95xRnd7og== Date: Sun, 21 Apr 2024 21:33:16 +0000 From: Michael Mauger <mmauger@HIDDEN> Message-ID: <JlL4q_VY4eAPjikV2Lq6XaCFr42uqj6t8KqT-kl50nf5Vy9gpwEcgzzgn4mmxwGfcfYWqkE0-WcpqMeYJxSnufTdOHCN0ENteicV5KUTk-o=@protonmail.com> In-Reply-To: <86le6rye7v.fsf@HIDDEN> References: <2110e7d1-153c-412a-a0dc-37531a0b6d84@HIDDEN> <864jduuxy1.fsf@HIDDEN> <86le6rye7v.fsf@HIDDEN> Feedback-ID: 119932:user:proton X-Pm-Message-ID: 4ec0cb7260063b8aebae0d94f1e7b47b40abdf32 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: 1.0 (+) X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -1.0 (-) On Saturday, March 9th, 2024 at 3:57 AM, Eli Zaretskii <eliz@HIDDEN> wrote= : > Ping! Michael, any comments? >=20 Sorry for the delay--the fix looks reasonable. I'm unable to do any real te= sting right now, and I don't use the `sql-send-*` myself and have a limited= setup currently. I'm recovering from cardiac surgery, along with a severe hamstring injury i= n Sep '23, which has kept me out of commission for much of the last six mon= ths. I'm slowly crawling out of the hole and hope to be back bt LibrePlanet= in early May. > > Cc: 69420 <at> debbugs.gnu.org > > Date: Tue, 27 Feb 2024 10:13:26 +0200 > > From: Eli Zaretskii eliz@HIDDEN > >=20 > > > Date: Mon, 26 Feb 2024 23:56:05 -0500 > > > From: Gary Hollis ghollisjr@HIDDEN > > >=20 > > > When the point is not at the very end of the iSQL buffer, the > > > process-mark is not kept in a reasonable state if sql-send-string is > > > called. > > >=20 > > > Example to reproduce bug: > > > 1. Open a sql-mode buffer. > > > 2. Connect to a SQL database of choice. > > > 3. Move the point of the iSQL buffer to the top, e.g. with M-< > > > 4. Send good queries via sql-send-string, sql-send-region etc. > > > 5. In iSQL buffer, move point to end, e.g. with M-> > > > 6. Enter a good query. > > >=20 > > > Expected result: The new query successfully sends and sql process > > > returns output. > > > Actual result: Whatever contents had been output from the > > > sql-send-string, sql-send-region etc. will be sent along with the new= query. > > >=20 > > > To fix: a call to (end-of-buffer) can be placed within the > > > (save-excursion ...) context before sending any input in the > > > sql-send-string function, e.g. > > >=20 > > > ;; from sql.el with fix for bug added with BUG FIX comment: > > > (defun sql-send-string (str) > > > "Send the string STR to the SQL process." > > > (interactive "sSQL Text: ") > > >=20 > > > (let ((comint-input-sender-no-newline nil) > > > (s (replace-regexp-in-string "[[:space:]\n\r]+\\'" "" str))) > > > (if (sql-buffer-live-p sql-buffer) > > > (progn > > > ;; Ignore the hoping around... > > > (save-excursion > > > ;; Set product context > > > (with-current-buffer sql-buffer > > > (end-of-buffer) ; BUG FIX: correct point before sending input > > > (when sql-debug-send > > > (message ">>SQL> %S" s)) > > > (insert "\n") > > > (comint-set-process-mark) > > >=20 > > > ;; Send the string (trim the trailing whitespace) > > > (sql-input-sender (get-buffer-process (current-buffer)) s) > > >=20 > > > ;; Send a command terminator if we must > > > (sql-send-magic-terminator sql-buffer s sql-send-terminator) > > >=20 > > > (when sql-pop-to-buffer-after-send-region > > > (message "Sent string to buffer %s" sql-buffer)))) > > >=20 > > > ;; Display the sql buffer > > > (sql-display-buffer sql-buffer)) > > >=20 > > > ;; We don't have no stinkin' sql > > > (user-error "No SQL process started")))) > >=20 > > Thanks. > >=20 > > Michael, any comments or suggestions?
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997 nCipher Corporation Ltd,
1994-97 Ian Jackson.