From debbugs-submit-bounces@debbugs.gnu.org Tue Feb 18 15:28:17 2025 Received: (at submit) by debbugs.gnu.org; 18 Feb 2025 20:28:17 +0000 Received: from localhost ([127.0.0.1]:34113 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tkUCW-0004SH-DY for submit@debbugs.gnu.org; Tue, 18 Feb 2025 15:28:17 -0500 Received: from lists.gnu.org ([2001:470:142::17]:56630) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1tkUCT-0004Rj-Hy for submit@debbugs.gnu.org; Tue, 18 Feb 2025 15:28:14 -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 ) id 1tkUCN-0003ZL-VO for bug-gnu-emacs@gnu.org; Tue, 18 Feb 2025 15:28:07 -0500 Received: from mail-lj1-x22b.google.com ([2a00:1450:4864:20::22b]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1tkUCL-0004R7-HU for bug-gnu-emacs@gnu.org; Tue, 18 Feb 2025 15:28:07 -0500 Received: by mail-lj1-x22b.google.com with SMTP id 38308e7fff4ca-30761be8fa7so60646541fa.2 for ; Tue, 18 Feb 2025 12:28:04 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1739910482; x=1740515282; darn=gnu.org; h=mime-version:message-id:date:subject:to:from:from:to:cc:subject :date:message-id:reply-to; bh=WEBERobgB/PtOnvzazYPv3BUycHn27VX4sTDhzxqBKo=; b=L9CIvYv0U3LOVnyZzRChKfdTtQvxD6oHhJZiSOxNDtrBy5N0lVRfAdXMW/LZM8alPl pP3tiDGd+WgGnYOVk9zepreJVoXNFPEnpulHFzOJSMBpJz/oDtT5hQMlUbJnp0XonVzZ pMKYyJxMIdCTREt2w5xDGb1DzAu3NwJr26BkNm7Jbzw8cnhB2SnHisCM8uasRgqlNiI+ aXNoUqV152zG24Q9ngXnIieidruqDuYp/kS/GYDXNL0uAqN7bqwgsEI+F8c29fKMrSEp pKHdeTPp5t7oUVLbujp2jQyxtyy3Iw+sR1MaWWtAz5Lcj06ViW8prJuEnZRCumfbV325 3IDQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1739910482; x=1740515282; h=mime-version:message-id:date:subject:to:from:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=WEBERobgB/PtOnvzazYPv3BUycHn27VX4sTDhzxqBKo=; b=nrYMGQYxP3ZZP3AzDffuMnvewsFw1xRBEBDumSpxRCLaGMgwra5I7I8Llua8Vz4OXl 6YXQsHx70Vr+w+A7O68biS324Q7vWoaNaPmSi9vUT1xJMrp/a8ffyRRFyWpm0dvadI9q D4vL2Gb3DrepcIxbPcp4XiH9fK3xM2KMcuU/5/4fVW2eMXYMAwM14isNJlng/Nb5zxZL 0+Jw/dgd+2YukF7khX/IVSMMtNokfuF419mBkX08pzQuxbl+Gs8zv0XuWS6oMg+FESM6 X9AcWUbbnsOC7cGM4eaWYPORYWUzYgVqKudRILdNTuygjpbeezCh1uRyP0p9dxFBsk5T M6CA== X-Gm-Message-State: AOJu0Ywwae0jOS7q0ru3pnWrrnlN2ZpDeldmKcm9ipmtmXdBd6CbsNeR KauIsKei4P0Az/BiTnVdREgAas13aPzor8UfO9XFstY5OE1qNK5f5kmMOg== X-Gm-Gg: ASbGncuFZvgQOd4SLxUnmfIoC/S6XA2KP/IJ0pCmPvqz9ddJZsXdBhwzbpG1vhWDLZ1 O2mwYNIjQBkzpZmS/W9oAnNWAsAM90FWEo7tNZSed8NBbW7EMYR6en7SI+iV606Lrl9cE+nE5FB cA6hX+b6808envzY+Fz0TN+B19MeMaAlNWGnk6/kXq+UaZGDft1XfHjcisccVHVyK35DUPYgPmC 5H9iJ7cXcfKWgugqYgFo2YTz+RDpS7RPlP604t3x+t5LeXe7D8N2l7XFuHmlTrkrthxCWCQHF3u 9YjAzxOjnCKs6fXqZ4A0bIqibh0qBQqkeUigGEBkuA== X-Google-Smtp-Source: AGHT+IHPXNVryoyvmQEKamd9CSJpdSXVCibuJcpU+foB313LNl0Ng4swq4udiz5kadOW1ADq6dj95Q== X-Received: by 2002:a05:6512:1244:b0:545:3031:40aa with SMTP id 2adb3069b0e04-5462eedb5c2mr381778e87.9.1739910481905; Tue, 18 Feb 2025 12:28:01 -0800 (PST) Received: from trevarch (109-252-32-232.nat.spd-mgts.ru. [109.252.32.232]) by smtp.gmail.com with ESMTPSA id 2adb3069b0e04-54620544eacsm858297e87.136.2025.02.18.12.27.59 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 18 Feb 2025 12:28:00 -0800 (PST) From: Trevor Arjeski To: bug-gnu-emacs@gnu.org Subject: 31.0.50; ERC 5.6.1-git: new erc query buffer becomes sole window on RET X-Debbugs-CC: emacs-erc@gnu.org X-Debbugs-Cc: Date: Tue, 18 Feb 2025 23:27:58 +0300 Message-ID: <87seob9ewh.fsf@gmail.com> MIME-Version: 1.0 Content-Type: text/plain Received-SPF: pass client-ip=2a00:1450:4864:20::22b; envelope-from=tmarjeski@gmail.com; helo=mail-lj1-x22b.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 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: 1.0 (+) 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: -0.0 (/) Using a few new emacs 31 window configurations, upon creating a new erc query buffer with `/query yournick`, hitting RET or sending a message makes the window the sole window in the frame as if C-x 1 was entered. Minimal reproduction: (use-package window :custom (kill-buffer-quit-windows t) (quit-restore-window-no-switch 'skip-first)) 1. Start erc 2. Open a query from the server buffer with `/query trev` 3. Hit enter 4. Notice that the query buffer that was created as a split becomes the only window in the frame. This seems to trigger in `erc--split-line` in erc-backend.el, where a temp buffer is created and then subsequently killed. In GNU Emacs 31.0.50 (build 10, x86_64-pc-linux-gnu, GTK+ Version 3.24.48, cairo version 1.18.2) of 2025-02-14 built on trevarch Repository revision: 4d6f40dfc9075d64275da97dc35a2becc9eca4a2 Repository branch: makepkg System Description: Arch Linux Configured using: 'configure --prefix=/usr --sysconfdir=/etc --libexecdir=/usr/lib --localstatedir=/var --mandir=/usr/share/man --with-gameuser=:games --with-modules --without-m17n-flt --without-gconf --with-native-compilation=yes --with-xinput2 --with-pgtk --without-xaw3d --with-sound=no --with-tree-sitter --without-gpm --without-compress-install '--program-transform-name=s/\([ec]tags\)/\1.emacs/' 'CFLAGS=-march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions -Wp,-D_FORTIFY_SOURCE=3 -Wformat -Werror=format-security -fstack-clash-protection -fcf-protection -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer -Wno-implicit-function-declaration -g -ffile-prefix-map=/home/trev/Workspace/emacs-git/src=/usr/src/debug/emacs-git -flto=auto' 'LDFLAGS=-Wl,-O1 -Wl,--sort-common -Wl,--as-needed -Wl,-z,relro -Wl,-z,now -Wl,-z,pack-relative-relocs -flto=auto'' Configured features: ACL CAIRO DBUS FREETYPE GIF GLIB GMP GNUTLS GSETTINGS HARFBUZZ JPEG LCMS2 LIBOTF LIBSYSTEMD LIBXML2 MODULES NATIVE_COMP NOTIFY INOTIFY PDUMPER PGTK PNG RSVG SECCOMP SQLITE3 THREADS TIFF TOOLKIT_SCROLL_BARS TREE_SITTER WEBP XIM GTK3 ZLIB Important settings: value of $LC_ALL: en_US.UTF-8 value of $LC_CTYPE: en_US.UTF-8 value of $LANG: en_US.UTF-8 locale-coding-system: utf-8-unix Major mode: ELisp/l Minor modes in effect: erc-track-mode: t erc-track-minor-mode: t erc-spelling-mode: t erc-ring-mode: t erc-netsplit-mode: t erc-menu-mode: t erc-match-mode: t erc-list-mode: t erc-irccontrols-mode: t erc-move-to-prompt-mode: t erc-readonly-mode: t erc-scrolltobottom-mode: t erc-imenu-mode: t erc-pcomplete-mode: t erc-button-mode: t erc-fill-mode: t erc-stamp-mode: t erc-autojoin-mode: t erc-networks-mode: t diff-hl-flydiff-mode: t global-diff-hl-mode: t diff-hl-mode: t paredit-mode: t display-line-numbers-mode: t ligature-mode: t rainbow-delimiters-mode: t format-all-mode: t global-auto-revert-mode: t repeat-mode: t ws-butler-global-mode: t ws-butler-mode: t global-treesit-auto-mode: t corfu-popupinfo-mode: t global-corfu-mode: t corfu-mode: t marginalia-mode: t savehist-mode: t vertico-mode: t auto-insert-mode: t undo-fu-session-global-mode: t undo-fu-session-mode: t which-key-mode: t electric-pair-mode: t desktop-save-mode: t recentf-mode: t save-place-mode: t override-global-mode: t global-eldoc-mode: t eldoc-mode: t show-paren-mode: t electric-indent-mode: t mouse-wheel-mode: t file-name-shadow-mode: t global-font-lock-mode: t font-lock-mode: t blink-cursor-mode: t window-divider-mode: t minibuffer-regexp-mode: t column-number-mode: t line-number-mode: t auto-fill-function: do-auto-fill transient-mark-mode: t auto-composition-mode: t auto-encryption-mode: t Load-path shadows: ~/.emacs.d//lisp/aoc hides /home/trev/.emacs.d/elpa/aoc-1.0.0/aoc ~/.emacs.d//lisp/launch-program hides /home/trev/.emacs.d/elpa/launch-program-1.0.0/launch-program ~/.emacs.d//lisp/my-secrets hides /home/trev/.emacs.d/elpa/my-secrets-1.0.0/my-secrets Features: (shadow sort mail-extr emacsbug pulse bug-reference eglot external-completion jsonrpc flymake ert pcase c++-ts-mode c-ts-mode c-ts-common xref project cc-mode cc-fonts cc-guess cc-menus cc-cmds cc-styles cc-align cc-engine comp comp-cstr warnings thingatpt helpful cc-langs cc-vars cc-defs trace cl-print edebug debug backtrace info-look find-func f help-fns radix-tree elisp-refs s comp-run comp-common novice misearch multi-isearch mule-util orderless cape-char cape network-stream nsm erc-track erc-spelling flyspell ispell erc-ring erc-nicks erc-netsplit erc-menu erc-match erc-list erc-goodies erc-imenu imenu erc-pcomplete pcomplete erc-button erc-fill erc-stamp erc-join my-secrets cus-start epa-file erc format-spec erc-backend erc-networks erc-common erc-compat erc-loaddefs diff-hl-flydiff diff diff-hl log-view log-edit message sendmail yank-media puny dired dired-loaddefs rfc822 mml mml-sec epa derived epg rfc6068 epg-config mm-decode mm-bodies mm-encode mail-parse rfc2231 rfc2047 rfc2045 ietf-drums mailabbrev gmm-utils mailheader add-log pcvs-util vc-dir ewoc vc vc-git diff-mode track-changes files-x vc-dispatcher jka-compr paredit display-line-numbers rx ligature rainbow-delimiters format-all language-id inheritenv autorevert filenotify repeat init gnus nnheader gnus-util time-date mail-utils range mm-util mail-prsvr cus-edit pp ws-butler treesit-auto treesit corfu-popupinfo corfu marginalia savehist vertico compat autoinsert grep compile text-property-search comint ansi-osc ansi-color ring cus-load undo-fu-session which-key diminish finder-inf edmacro kmacro elec-pair desktop frameset recentf tree-widget wid-edit saveplace nord-theme autothemer color lisp-mnt dash use-package use-package-ensure use-package-delight use-package-diminish use-package-bind-key bind-key easy-mmode package browse-url xdg 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 eieio eieio-core icons password-cache json subr-x map byte-opt url-vars cl-macs gv cl-extra help-mode cl-seq use-package-core cl-loaddefs cl-lib bytecomp byte-compile info 2048-game-autoloads ace-window-autoloads aio-autoloads aoc-autoloads autothemer-autoloads avy-autoloads benchmark-init-autoloads cape-autoloads corfu-autoloads debbugs-autoloads diff-hl-autoloads diminish-autoloads elfeed-autoloads emacsql-autoloads envrc-autoloads format-all-autoloads geiser-guile-autoloads geiser-autoloads git-modes-autoloads heap-autoloads helpful-autoloads elisp-refs-autoloads f-autoloads ht-autoloads inheritenv-autoloads language-id-autoloads launch-program-autoloads ligature-autoloads log4e-autoloads magit-autoloads magit-section-autoloads dash-autoloads marginalia-autoloads markdown-mode-autoloads my-secrets-autoloads orderless-autoloads paredit-autoloads rainbow-delimiters-autoloads rainbow-mode-autoloads request-autoloads rust-mode-autoloads s-autoloads sly-autoloads treesit-auto-autoloads undo-fu-autoloads undo-fu-session-autoloads vertico-autoloads vterm-autoloads with-editor-autoloads ws-butler-autoloads early-init rmc iso-transl tooltip cconv eldoc paren electric uniquify ediff-hook vc-hooks lisp-float-type elisp-mode mwheel term/pgtk-win pgtk-win term/common-win touch-screen pgtk-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 dynamic-setting system-font-setting font-render-setting cairo gtk pgtk lcms2 multi-tty move-toolbar make-network-process tty-child-frames native-compile emacs) Memory information: ((conses 16 753787 456549) (symbols 48 29546 38) (strings 32 122308 34583) (string-bytes 1 4464676) (vectors 16 60371) (vector-slots 8 1478094 442007) (floats 8 389 931) (intervals 56 35024 2770) (buffers 992 38)) From debbugs-submit-bounces@debbugs.gnu.org Tue Feb 18 22:38:33 2025 Received: (at 76404) by debbugs.gnu.org; 19 Feb 2025 03:38:33 +0000 Received: from localhost ([127.0.0.1]:38600 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tkauv-0001gS-1V for submit@debbugs.gnu.org; Tue, 18 Feb 2025 22:38:33 -0500 Received: from mail-108-mta19.mxroute.com ([136.175.108.19]:46121) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.84_2) (envelope-from ) id 1tkaur-0001g0-TI for 76404@debbugs.gnu.org; Tue, 18 Feb 2025 22:38:31 -0500 Received: from filter006.mxroute.com ([136.175.111.3] filter006.mxroute.com) (Authenticated sender: mN4UYu2MZsgR) by mail-108-mta19.mxroute.com (ZoneMTA) with ESMTPSA id 1951c491313000310e.001 for <76404@debbugs.gnu.org> (version=TLSv1.3 cipher=TLS_AES_256_GCM_SHA384); Wed, 19 Feb 2025 03:38:25 +0000 X-Zone-Loop: 3e030b569f49ea6e33b4a63c5ce56f6e45b1d71d813d X-Originating-IP: [136.175.111.3] DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=neverwas.me ; s=x; h=Content-Type:MIME-Version:Message-ID:Date:References:In-Reply-To: Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:List-Subscribe: List-Post:List-Owner:List-Archive; bh=YgahbkrBF6GcmHN1JjE8Xh4m/1YGT9M6/1b+ci301OU=; b=ggd87+3vSFCuO6ItdYY/UW+ea8 gNobG25jnA5HX4iERgNnLkCOJ0walsxNIXaU17dqthtWxGQhGumRVTme5pz0+vvpV/Fa2cr2+13+t Gp1rNn2idbJzpg+i4QeQimOEwCCcNjqQbH21nErW6gCXV3UCCDo+SVct0BqkS9WCPPKLFlIIjSkIP rzjqrEZ+/2CyuL3Xb6qrxRapqRGtoABkqHYjyj8/rqLtk3v9QZeXxDl6AjZiUImZhB/39x9PtcXuL F9LZDlRw331cxWzGIiDIowVJuT4fdHKXMuRAe0pPs+iNnAbxg3+heDR2qHVZ0lHFdy/JWe18wwRFw Jaqy7zVw==; From: "J.P." To: Trevor Arjeski Subject: Re: bug#76404: 31.0.50; ERC 5.6.1-git: new erc query buffer becomes sole window on RET In-Reply-To: <87seob9ewh.fsf@gmail.com> References: <87seob9ewh.fsf@gmail.com> Date: Tue, 18 Feb 2025 19:38:23 -0800 Message-ID: <87v7t6k3io.fsf@neverwas.me> User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Authenticated-Id: masked@neverwas.me X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 76404 Cc: emacs-erc@gnu.org, 76404@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.0 (-) --=-=-= Content-Type: text/plain Trevor Arjeski writes: > Using a few new emacs 31 window configurations, upon creating a new erc > query buffer with `/query yournick`, hitting RET or sending a message > makes the window the sole window in the frame as if C-x 1 was entered. > > Minimal reproduction: > > (use-package window > :custom > (kill-buffer-quit-windows t) > (quit-restore-window-no-switch 'skip-first)) > > 1. Start erc > 2. Open a query from the server buffer with `/query trev` > 3. Hit enter > 4. Notice that the query buffer that was created as a split becomes the > only window in the frame. > > This seems to trigger in `erc--split-line` in erc-backend.el, where a > temp buffer is created and then subsequently killed. Thanks for investigating. Does the attached patch improve the situation? --=-=-= Content-Type: text/x-patch Content-Disposition: attachment; filename=0001-5.6.1-Don-t-kill-window-buffer-in-erc-split-line.patch >From 4b9a02f7b46f84d8a78a671d2bb2fa246f102c46 Mon Sep 17 00:00:00 2001 From: "F. Jason Park" Date: Tue, 18 Feb 2025 19:20:45 -0800 Subject: [PATCH] [5.6.1] Don't kill window buffer in erc--split-line * lisp/erc/erc-backend.el (erc--split-line): Restore original window buffer before killing temp buffer. (Bug#76404) --- lisp/erc/erc-backend.el | 57 +++++++++++++++++++++-------------------- 1 file changed, 29 insertions(+), 28 deletions(-) diff --git a/lisp/erc/erc-backend.el b/lisp/erc/erc-backend.el index 713547a591a..e9b39a6f3f4 100644 --- a/lisp/erc/erc-backend.el +++ b/lisp/erc/erc-backend.el @@ -588,34 +588,35 @@ erc--split-line (when (consp coding) (setq coding (car coding))) (setq coding (coding-system-change-eol-conversion coding 'unix)) - (unwind-protect - (with-temp-buffer - (set-window-buffer (selected-window) (current-buffer)) - (insert longline) - (goto-char (point-min)) - (while (not (eobp)) - (let ((upper (filepos-to-bufferpos erc-split-line-length - 'exact coding))) - (goto-char (or upper (point-max))) - (unless (eobp) - (skip-chars-backward "^ \t")) - (when (bobp) - (when erc--reject-unbreakable-lines - (user-error - (substitute-command-keys - (concat "Unbreakable line encountered " - "(Recover input with \\[erc-previous-command])")))) - (goto-char upper)) - (when-let* ((cmp (find-composition (point) (1+ (point))))) - (if (= (car cmp) (point-min)) - (goto-char (nth 1 cmp)) - (goto-char (car cmp))))) - (when (= (point-min) (point)) - (goto-char (point-max))) - (push (buffer-substring-no-properties (point-min) (point)) out) - (delete-region (point-min) (point))) - (or (nreverse out) (list ""))) - (set-window-buffer (selected-window) original-window-buf)))) + (with-temp-buffer + (unwind-protect + (progn + (set-window-buffer (selected-window) (current-buffer)) + (insert longline) + (goto-char (point-min)) + (while (not (eobp)) + (let ((upper (filepos-to-bufferpos erc-split-line-length + 'exact coding))) + (goto-char (or upper (point-max))) + (unless (eobp) + (skip-chars-backward "^ \t")) + (when (bobp) + (when erc--reject-unbreakable-lines + (user-error + (substitute-command-keys + (concat "Unbreakable line encountered (Recover input" + " with \\[erc-previous-command])")))) + (goto-char upper)) + (when-let* ((cmp (find-composition (point) (1+ (point))))) + (if (= (car cmp) (point-min)) + (goto-char (nth 1 cmp)) + (goto-char (car cmp))))) + (when (= (point-min) (point)) + (goto-char (point-max))) + (push (buffer-substring-no-properties (point-min) (point)) out) + (delete-region (point-min) (point))) + (or (nreverse out) (list ""))) + (set-window-buffer (selected-window) original-window-buf))))) ;; From Circe (defun erc-split-line (longline) -- 2.48.1 --=-=-=-- From debbugs-submit-bounces@debbugs.gnu.org Tue Feb 18 23:39:07 2025 Received: (at 76404) by debbugs.gnu.org; 19 Feb 2025 04:39:07 +0000 Received: from localhost ([127.0.0.1]:39258 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tkbrW-0000Ch-W4 for submit@debbugs.gnu.org; Tue, 18 Feb 2025 23:39:07 -0500 Received: from mail-lj1-x231.google.com ([2a00:1450:4864:20::231]:50569) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.84_2) (envelope-from ) id 1tkbrU-0000BW-67 for 76404@debbugs.gnu.org; Tue, 18 Feb 2025 23:39:05 -0500 Received: by mail-lj1-x231.google.com with SMTP id 38308e7fff4ca-3098088c630so35000571fa.1 for <76404@debbugs.gnu.org>; Tue, 18 Feb 2025 20:39:04 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1739939937; x=1740544737; darn=debbugs.gnu.org; h=mime-version:user-agent:message-id:date:references:in-reply-to :subject:cc:to:from:from:to:cc:subject:date:message-id:reply-to; bh=h0jVqwj67J7OEZ13Kjt+JtEtJBVf3inX3gK55oKGOxs=; b=VObTtLxcxWUNgjALMgO4rDM2mlKzf6e/OmgikbmOuLs0GL0urWyPONLRQZpGzoyFvI q3PDOqRuOBFxqP/pyLAb4C9fydqTDJLXX1kuwqTdv9AZHUhk68BzWWOkKA0hoXQaMeE9 2pMXk8gKynvVN8E+ugeEiAQKgnHP/D6g+smqX4JbKWwmN1pkqZADInNvjp4MBF8D5MNu Pbnom16Mz4X4Pr4DNldARtWYBrfsSkpxiYafWnrI7gTAsCnlZh8IfdztyZupMouKK7hh LO9pEvUbaSIyHj/l4ADD9RDWIM+0CWi5d8mGJTZ8PIEIM4Ph1Qno10MoN46yepZzvTjE A20A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1739939937; x=1740544737; h=mime-version:user-agent:message-id:date:references:in-reply-to :subject:cc:to:from:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=h0jVqwj67J7OEZ13Kjt+JtEtJBVf3inX3gK55oKGOxs=; b=gtfISiQr6pt0PRVRyBQos6zPzHamOOsy9IAlYauJ8pSWnHaRimMLNiSsuca8zqzKzx fnLh0tQlh2HnOi4R3eUyIy6k4ywz4CEq4HhvJ+m1SOfQ7bhM6cbZgEf4oZIgxS6IO1KP kcuGraHUlTPcZiYyLrGmpqUCuKQBXmftAX02lnL/amNgk0eBTWIWXoL2tSAjyL3F4cdg tcHyZH9jyLgBgnBcWyyPVRREbcXQIHsFLYPrPNu4m6QzZhhRMWKQ0Qhr5bj/64t6ldhX uRiZAx9rJcGyAti0XlfjRsSfMgekogPXa0g5UTS1VO0/iM/6OMwCwy/siL49s83+07sl 6hsA== X-Gm-Message-State: AOJu0YwRa2dq8AXFooFVyMURp/uCgyhs5ufrWO3BmjOGDCxVM7nBCBX1 55dZpGhCzaQ1Pf0a2TKQf2EOZ7xtEkD9ezittPFyBAcn0OxgMYgC X-Gm-Gg: ASbGncvmcYxF9BLv90TXkezP3gbU5VboN99yQOCCTeP+3+xn89aawHELbq3w8wjnest QPotV12t4fldAprzf/cGSnGH5z4WiZwwwog4DwQ0Gy3zqDnv5x3bZwP7pnGy3NgSxSUp4s9BSzT xBBGOjsayBwi1zvSipd4+icb56N2e7euXEo/SlP8GYhXCj22C+LxzuLDyEU4I+fxXzdP0WlA7jN BV0knxMSJRsyu8+d4kmUU2W0OQG6X7sJOYo9nPg7kOh6xpsZe2BpXJGYeUObyjzpG+1b0P2dCSg Sfgx4nHbhQXB4tNanjern76az7r58CHhOb5iFibFjQ== X-Google-Smtp-Source: AGHT+IFVDepFBrExLTKZbbqtzrB8RtJD+1hIcseUcckXv9PyoLMMoQWm5SNiSRJBJxAthO2Jz9k12A== X-Received: by 2002:a05:6512:401b:b0:544:f93:6909 with SMTP id 2adb3069b0e04-5452fe653b3mr5006978e87.30.1739939936626; Tue, 18 Feb 2025 20:38:56 -0800 (PST) Received: from trevarch (109-252-32-232.nat.spd-mgts.ru. [109.252.32.232]) by smtp.gmail.com with ESMTPSA id 2adb3069b0e04-54621040432sm865778e87.55.2025.02.18.20.38.54 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 18 Feb 2025 20:38:55 -0800 (PST) From: Trevor Arjeski To: "J.P." Subject: Re: bug#76404: 31.0.50; ERC 5.6.1-git: new erc query buffer becomes sole window on RET In-Reply-To: <87v7t6k3io.fsf@neverwas.me> References: <87seob9ewh.fsf@gmail.com> <87v7t6k3io.fsf@neverwas.me> Date: Wed, 19 Feb 2025 07:38:53 +0300 Message-ID: <87msei5z1e.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 76404 Cc: emacs-erc@gnu.org, 76404@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.0 (-) "J.P." writes: > Trevor Arjeski writes: > >> Using a few new emacs 31 window configurations, upon creating a new erc >> query buffer with `/query yournick`, hitting RET or sending a message >> makes the window the sole window in the frame as if C-x 1 was entered. >> >> Minimal reproduction: >> >> (use-package window >> :custom >> (kill-buffer-quit-windows t) >> (quit-restore-window-no-switch 'skip-first)) >> >> 1. Start erc >> 2. Open a query from the server buffer with `/query trev` >> 3. Hit enter >> 4. Notice that the query buffer that was created as a split becomes the >> only window in the frame. >> >> This seems to trigger in `erc--split-line` in erc-backend.el, where a >> temp buffer is created and then subsequently killed. > > Thanks for investigating. Does the attached patch improve the situation? Thanks, this works! Trevor From debbugs-submit-bounces@debbugs.gnu.org Sat Mar 01 13:16:06 2025 Received: (at 76404-done) by debbugs.gnu.org; 1 Mar 2025 18:16:07 +0000 Received: from localhost ([127.0.0.1]:43377 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1toRNe-0000Yz-Cr for submit@debbugs.gnu.org; Sat, 01 Mar 2025 13:16:06 -0500 Received: from mail-108-mta26.mxroute.com ([136.175.108.26]:37711) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.84_2) (envelope-from ) id 1toRNb-0000Tt-A2 for 76404-done@debbugs.gnu.org; Sat, 01 Mar 2025 13:16:04 -0500 Received: from filter006.mxroute.com ([136.175.111.3] filter006.mxroute.com) (Authenticated sender: mN4UYu2MZsgR) by mail-108-mta26.mxroute.com (ZoneMTA) with ESMTPSA id 19552ec1eec000310e.001 for <76404-done@debbugs.gnu.org> (version=TLSv1.3 cipher=TLS_AES_256_GCM_SHA384); Sat, 01 Mar 2025 18:16:01 +0000 X-Zone-Loop: 5119e89da211bf91a6d34db5535fa00d0099d5fef27d X-Originating-IP: [136.175.111.3] DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=neverwas.me ; s=x; h=Content-Type:MIME-Version:Message-ID:Date:References:In-Reply-To: Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:List-Subscribe: List-Post:List-Owner:List-Archive; bh=m97X7eG4sCxqe3jusWwItRyFxMX4KV+NRI9xu/zsJdA=; b=UJBGlK1VQMjz3SpzfQMY+eg7sG xWrhfaLlOxi4ACSMl3qUgcPls/z+WBG3E0GYGnMRp/ywS3TzQKdDDNRzlPhm/kbIXJFaDnxtOze8O 3tKVI0FwP6tPlm2tUznelWPBMuWtJf801GLVIF8kS8QHvxgXFEFfydQVzcAmFFK4LX+bpv/Ta5xO9 ho6cO0ouHK15UfkuL8u9+bAlaUcSpFqMhn5G2SwJhQj4KCOfReEL4im9U7oFLLLqSfm9nSkSxOjED qSES3jHUmLeSfsF7U7P1QQlIKTbyZtHHyBOzKz+MiijmEUGwUq3zGuHpRTaf9bB2pvI843P28Ek42 rcMRRJZA==; From: "J.P." To: Trevor Arjeski Subject: Re: bug#76404: 31.0.50; ERC 5.6.1-git: new erc query buffer becomes sole window on RET In-Reply-To: <87msei5z1e.fsf@gmail.com> References: <87seob9ewh.fsf@gmail.com> <87v7t6k3io.fsf@neverwas.me> <87msei5z1e.fsf@gmail.com> Date: Sat, 01 Mar 2025 10:15:56 -0800 Message-ID: <87o6ykhb1f.fsf@neverwas.me> User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: text/plain X-Authenticated-Id: masked@neverwas.me X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 76404-done Cc: emacs-erc@gnu.org, 76404-done@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.0 (-) Trevor Arjeski writes: > "J.P." writes: > >> Thanks for investigating. Does the attached patch improve the situation? > > Thanks, this works! > Installed as https://git.savannah.gnu.org/cgit/emacs.git/commit/?id=1270e6ae Thanks and closing From unknown Fri Aug 08 19:15:09 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Sun, 30 Mar 2025 11:24:07 +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