GNU bug report logs - #72117
Command doesn't execute correctly in eshell

Previous Next

Package: emacs;

Reported by: the_wurfkreuz <the_wurfkreuz <at> proton.me>

Date: Sun, 14 Jul 2024 19:34:01 UTC

Severity: normal

Done: Jim Porter <jporterbugs <at> gmail.com>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 72117 in the body.
You can then email your comments to 72117 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-gnu-emacs <at> gnu.org:
bug#72117; Package emacs. (Sun, 14 Jul 2024 19:34:01 GMT) Full text and rfc822 format available.

Acknowledgement sent to the_wurfkreuz <the_wurfkreuz <at> proton.me>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs <at> gnu.org. (Sun, 14 Jul 2024 19:34:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: the_wurfkreuz <the_wurfkreuz <at> proton.me>
To: "bug-gnu-emacs <at> gnu.org" <bug-gnu-emacs <at> gnu.org>
Subject: Command doesn't execute correctly in eshell
Date: Sun, 14 Jul 2024 19:33:16 +0000
[Message part 1 (text/plain, inline)]
First of all, i can't execute 'sudo lsof | grep delete | head -10' in
eshell. But that's not the most interesting part. I can execute the
command with 'eshell/sudo'. But after the command execution emacs will
take the whole CPU processing time if i have '(global-display-line-numbers-mode 1)'
option enabled.

Steps to reproduce:

1. emacs -Q
2. M-x 'eshell'
3. sudo lsof | grep delete | head -10
4. send SIGINT
5. (require 'em-tramp)
6. eshell/sudo lsof | grep delete | head -10
7. execute '(global-display-line-numbers-mode 1)'.
You might get CPU 100% right after the command execution.
8. eshell/sudo lsof | grep delete | head -10

Now CPU usage at 100%.

In GNU Emacs 30.0.50 (build 1, x86_64-pc-linux-gnu, GTK+ Version
3.24.41, cairo version 1.18.0) of 2024-04-23 built on archlinux
Repository revision: 326437e6c8a6497b1a38d002b1d28e74678a07aa
Repository branch: master
Windowing system distributor 'The X.Org Foundation', version 11.0.12401000
System Description: Arch Linux

Configured using:
'configure --with-native-compilation=aot --with-tree-sitter --with-gif
--with-png --with-jpeg --with-rsvg --with-tiff --with-imagemagick
--with-x-toolkit=gtk3 --with-xwidgets
CPPFLAGS=-I/opt/homebrew/opt/jpeg/include
LDFLAGS=-L/opt/homebrew/opt/jpeg/lib'

Configured features:
ACL CAIRO DBUS FREETYPE GIF GLIB GMP GNUTLS GPM GSETTINGS HARFBUZZ
IMAGEMAGICK JPEG LCMS2 LIBOTF LIBSYSTEMD LIBXML2 M17N_FLT MODULES
NATIVE_COMP NOTIFY INOTIFY PDUMPER PNG RSVG SECCOMP SOUND SQLITE3
THREADS TIFF TOOLKIT_SCROLL_BARS TREE_SITTER WEBP X11 XDBE XIM XINPUT2
XPM XWIDGETS GTK3 ZLIB

Important settings:
value of $LANG: en_US.UTF-8
locale-coding-system: utf-8-unix

Major mode: Org

Minor modes in effect:
windmove-mode: t
org-indent-mode: t
org-bullets-mode: t
pyvenv-mode: t
shackle-mode: t
popper-echo-mode: t
popper-mode: t
eshell-syntax-highlighting-global-mode: t
all-the-icons-ivy-rich-mode: t
ivy-rich-mode: t
counsel-mode: t
ivy-mode: t
override-global-mode: t
projectile-mode: t
global-fish-completion-mode: t
fish-completion-mode: t
corfu-popupinfo-mode: t
corfu-history-mode: t
corfu-echo-mode: t
global-corfu-mode: t
corfu-mode: t
yas-global-mode: t
yas-minor-mode: t
vimish-fold-global-mode: t
vimish-fold-mode: t
which-key-mode: t
dired-async-mode: t
general-override-mode: t
global-treesit-auto-mode: t
global-evil-collection-unimpaired-mode: t
evil-collection-unimpaired-mode: t
evil-org-mode: t
global-evil-surround-mode: t
evil-surround-mode: t
evil-mode: t
evil-local-mode: t
global-undo-tree-mode: t
undo-tree-mode: t
global-auto-revert-mode: t
pixel-scroll-precision-mode: t
save-place-mode: t
savehist-mode: t
electric-pair-mode: t
global-display-line-numbers-mode: t
display-line-numbers-mode: t
straight-use-package-mode: t
straight-package-neutering-mode: t
tooltip-mode: t
show-paren-mode: t
electric-indent-mode: t
mouse-wheel-mode: t
prettify-symbols-mode: t
tab-bar-mode: t
file-name-shadow-mode: t
global-font-lock-mode: t
font-lock-mode: t
minibuffer-regexp-mode: t
line-number-mode: t
auto-fill-function: #[128 \304\300\301#\207 [yas--auto-fill org-auto-fill-function :around nil apply] 5 advice]
transient-mark-mode: t
auto-composition-mode: t
auto-encryption-mode: t
auto-compression-mode: t

Load-path shadows:
/home/wurfkreuz/.emacs.d/straight/build/transient/transient hides /home/wurfkreuz/.source/emacs/lisp/transient
/home/wurfkreuz/.emacs.d/straight/build/bind-key/bind-key hides /home/wurfkreuz/.source/emacs/lisp/bind-key
/home/wurfkreuz/.emacs.d/straight/build/use-package/use-package hides /home/wurfkreuz/.source/emacs/lisp/use-package/use-package
/home/wurfkreuz/.emacs.d/straight/build/use-package/use-package-lint hides /home/wurfkreuz/.source/emacs/lisp/use-package/use-package-lint
/home/wurfkreuz/.emacs.d/straight/build/use-package/use-package-jump hides /home/wurfkreuz/.source/emacs/lisp/use-package/use-package-jump
/home/wurfkreuz/.emacs.d/straight/build/use-package/use-package-ensure hides /home/wurfkreuz/.source/emacs/lisp/use-package/use-package-ensure
/home/wurfkreuz/.emacs.d/straight/build/use-package/use-package-diminish hides /home/wurfkreuz/.source/emacs/lisp/use-package/use-package-diminish
/home/wurfkreuz/.emacs.d/straight/build/use-package/use-package-delight hides /home/wurfkreuz/.source/emacs/lisp/use-package/use-package-delight
/home/wurfkreuz/.emacs.d/straight/build/use-package/use-package-core hides /home/wurfkreuz/.source/emacs/lisp/use-package/use-package-core
/home/wurfkreuz/.emacs.d/straight/build/use-package/use-package-bind-key hides /home/wurfkreuz/.source/emacs/lisp/use-package/use-package-bind-key
/home/wurfkreuz/.emacs.d/straight/build/org/ox-publish hides /home/wurfkreuz/.source/emacs/lisp/org/ox-publish
/home/wurfkreuz/.emacs.d/straight/build/org/ox-org hides /home/wurfkreuz/.source/emacs/lisp/org/ox-org
/home/wurfkreuz/.emacs.d/straight/build/org/ox-odt hides /home/wurfkreuz/.source/emacs/lisp/org/ox-odt
/home/wurfkreuz/.emacs.d/straight/build/org/ox-md hides /home/wurfkreuz/.source/emacs/lisp/org/ox-md
/home/wurfkreuz/.emacs.d/straight/build/org/ox-man hides /home/wurfkreuz/.source/emacs/lisp/org/ox-man
/home/wurfkreuz/.emacs.d/straight/build/org/ox-latex hides /home/wurfkreuz/.source/emacs/lisp/org/ox-latex
/home/wurfkreuz/.emacs.d/straight/build/org/ox-koma-letter hides /home/wurfkreuz/.source/emacs/lisp/org/ox-koma-letter
/home/wurfkreuz/.emacs.d/straight/build/org/ox-icalendar hides /home/wurfkreuz/.source/emacs/lisp/org/ox-icalendar
/home/wurfkreuz/.emacs.d/straight/build/org/ox-html hides /home/wurfkreuz/.source/emacs/lisp/org/ox-html
/home/wurfkreuz/.emacs.d/straight/build/org/ox-beamer hides /home/wurfkreuz/.source/emacs/lisp/org/ox-beamer
/home/wurfkreuz/.emacs.d/straight/build/org/ox-ascii hides /home/wurfkreuz/.source/emacs/lisp/org/ox-ascii
/home/wurfkreuz/.emacs.d/straight/build/org/org hides /home/wurfkreuz/.source/emacs/lisp/org/org
/home/wurfkreuz/.emacs.d/straight/build/org/org-timer hides /home/wurfkreuz/.source/emacs/lisp/org/org-timer
/home/wurfkreuz/.emacs.d/straight/build/org/org-tempo hides /home/wurfkreuz/.source/emacs/lisp/org/org-tempo
/home/wurfkreuz/.emacs.d/straight/build/org/org-table hides /home/wurfkreuz/.source/emacs/lisp/org/org-table
/home/wurfkreuz/.emacs.d/straight/build/org/org-src hides /home/wurfkreuz/.source/emacs/lisp/org/org-src
/home/wurfkreuz/.emacs.d/straight/build/org/org-refile hides /home/wurfkreuz/.source/emacs/lisp/org/org-refile
/home/wurfkreuz/.emacs.d/straight/build/org/org-protocol hides /home/wurfkreuz/.source/emacs/lisp/org/org-protocol
/home/wurfkreuz/.emacs.d/straight/build/org/org-plot hides /home/wurfkreuz/.source/emacs/lisp/org/org-plot
/home/wurfkreuz/.emacs.d/straight/build/org/org-persist hides /home/wurfkreuz/.source/emacs/lisp/org/org-persist
/home/wurfkreuz/.emacs.d/straight/build/org/org-pcomplete hides /home/wurfkreuz/.source/emacs/lisp/org/org-pcomplete
/home/wurfkreuz/.emacs.d/straight/build/org/org-num hides /home/wurfkreuz/.source/emacs/lisp/org/org-num
/home/wurfkreuz/.emacs.d/straight/build/org/org-mouse hides /home/wurfkreuz/.source/emacs/lisp/org/org-mouse
/home/wurfkreuz/.emacs.d/straight/build/org/org-mobile hides /home/wurfkreuz/.source/emacs/lisp/org/org-mobile
/home/wurfkreuz/.emacs.d/straight/build/org/org-macs hides /home/wurfkreuz/.source/emacs/lisp/org/org-macs
/home/wurfkreuz/.emacs.d/straight/build/org/org-loaddefs hides /home/wurfkreuz/.source/emacs/lisp/org/org-loaddefs
/home/wurfkreuz/.emacs.d/straight/build/org/org-list hides /home/wurfkreuz/.source/emacs/lisp/org/org-list
/home/wurfkreuz/.emacs.d/straight/build/org/org-lint hides /home/wurfkreuz/.source/emacs/lisp/org/org-lint
/home/wurfkreuz/.emacs.d/straight/build/org/org-keys hides /home/wurfkreuz/.source/emacs/lisp/org/org-keys
/home/wurfkreuz/.emacs.d/straight/build/org/org-inlinetask hides /home/wurfkreuz/.source/emacs/lisp/org/org-inlinetask
/home/wurfkreuz/.emacs.d/straight/build/org/org-indent hides /home/wurfkreuz/.source/emacs/lisp/org/org-indent
/home/wurfkreuz/.emacs.d/straight/build/org/org-id hides /home/wurfkreuz/.source/emacs/lisp/org/org-id
/home/wurfkreuz/.emacs.d/straight/build/org/org-habit hides /home/wurfkreuz/.source/emacs/lisp/org/org-habit
/home/wurfkreuz/.emacs.d/straight/build/org/org-goto hides /home/wurfkreuz/.source/emacs/lisp/org/org-goto
/home/wurfkreuz/.emacs.d/straight/build/org/org-footnote hides /home/wurfkreuz/.source/emacs/lisp/org/org-footnote
/home/wurfkreuz/.emacs.d/straight/build/org/org-fold hides /home/wurfkreuz/.source/emacs/lisp/org/org-fold
/home/wurfkreuz/.emacs.d/straight/build/org/org-fold-core hides /home/wurfkreuz/.source/emacs/lisp/org/org-fold-core
/home/wurfkreuz/.emacs.d/straight/build/org/org-feed hides /home/wurfkreuz/.source/emacs/lisp/org/org-feed
/home/wurfkreuz/.emacs.d/straight/build/org/org-faces hides /home/wurfkreuz/.source/emacs/lisp/org/org-faces
/home/wurfkreuz/.emacs.d/straight/build/org/org-entities hides /home/wurfkreuz/.source/emacs/lisp/org/org-entities
/home/wurfkreuz/.emacs.d/straight/build/org/org-duration hides /home/wurfkreuz/.source/emacs/lisp/org/org-duration
/home/wurfkreuz/.emacs.d/straight/build/org/org-datetree hides /home/wurfkreuz/.source/emacs/lisp/org/org-datetree
/home/wurfkreuz/.emacs.d/straight/build/org/org-cycle hides /home/wurfkreuz/.source/emacs/lisp/org/org-cycle
/home/wurfkreuz/.emacs.d/straight/build/org/org-ctags hides /home/wurfkreuz/.source/emacs/lisp/org/org-ctags
/home/wurfkreuz/.emacs.d/straight/build/org/org-crypt hides /home/wurfkreuz/.source/emacs/lisp/org/org-crypt
/home/wurfkreuz/.emacs.d/straight/build/org/org-compat hides /home/wurfkreuz/.source/emacs/lisp/org/org-compat
/home/wurfkreuz/.emacs.d/straight/build/org/org-colview hides /home/wurfkreuz/.source/emacs/lisp/org/org-colview
/home/wurfkreuz/.emacs.d/straight/build/org/org-clock hides /home/wurfkreuz/.source/emacs/lisp/org/org-clock
/home/wurfkreuz/.emacs.d/straight/build/org/org-capture hides /home/wurfkreuz/.source/emacs/lisp/org/org-capture
/home/wurfkreuz/.emacs.d/straight/build/org/org-attach hides /home/wurfkreuz/.source/emacs/lisp/org/org-attach
/home/wurfkreuz/.emacs.d/straight/build/org/org-attach-git hides /home/wurfkreuz/.source/emacs/lisp/org/org-attach-git
/home/wurfkreuz/.emacs.d/straight/build/org/org-archive hides /home/wurfkreuz/.source/emacs/lisp/org/org-archive
/home/wurfkreuz/.emacs.d/straight/build/org/org-agenda hides /home/wurfkreuz/.source/emacs/lisp/org/org-agenda
/home/wurfkreuz/.emacs.d/straight/build/org/ol-w3m hides /home/wurfkreuz/.source/emacs/lisp/org/ol-w3m
/home/wurfkreuz/.emacs.d/straight/build/org/ol-rmail hides /home/wurfkreuz/.source/emacs/lisp/org/ol-rmail
/home/wurfkreuz/.emacs.d/straight/build/org/ol-mhe hides /home/wurfkreuz/.source/emacs/lisp/org/ol-mhe
/home/wurfkreuz/.emacs.d/straight/build/org/ol-man hides /home/wurfkreuz/.source/emacs/lisp/org/ol-man
/home/wurfkreuz/.emacs.d/straight/build/org/ol-irc hides /home/wurfkreuz/.source/emacs/lisp/org/ol-irc
/home/wurfkreuz/.emacs.d/straight/build/org/ol-info hides /home/wurfkreuz/.source/emacs/lisp/org/ol-info
/home/wurfkreuz/.emacs.d/straight/build/org/ol-gnus hides /home/wurfkreuz/.source/emacs/lisp/org/ol-gnus
/home/wurfkreuz/.emacs.d/straight/build/org/ol-eww hides /home/wurfkreuz/.source/emacs/lisp/org/ol-eww
/home/wurfkreuz/.emacs.d/straight/build/org/ol-eshell hides /home/wurfkreuz/.source/emacs/lisp/org/ol-eshell
/home/wurfkreuz/.emacs.d/straight/build/org/ol-doi hides /home/wurfkreuz/.source/emacs/lisp/org/ol-doi
/home/wurfkreuz/.emacs.d/straight/build/org/ol-docview hides /home/wurfkreuz/.source/emacs/lisp/org/ol-docview
/home/wurfkreuz/.emacs.d/straight/build/org/ol-bibtex hides /home/wurfkreuz/.source/emacs/lisp/org/ol-bibtex
/home/wurfkreuz/.emacs.d/straight/build/org/ol-bbdb hides /home/wurfkreuz/.source/emacs/lisp/org/ol-bbdb
/home/wurfkreuz/.emacs.d/straight/build/org/oc-natbib hides /home/wurfkreuz/.source/emacs/lisp/org/oc-natbib
/home/wurfkreuz/.emacs.d/straight/build/org/oc-csl hides /home/wurfkreuz/.source/emacs/lisp/org/oc-csl
/home/wurfkreuz/.emacs.d/straight/build/org/oc-bibtex hides /home/wurfkreuz/.source/emacs/lisp/org/oc-bibtex
/home/wurfkreuz/.emacs.d/straight/build/org/oc-biblatex hides /home/wurfkreuz/.source/emacs/lisp/org/oc-biblatex
/home/wurfkreuz/.emacs.d/straight/build/org/oc-basic hides /home/wurfkreuz/.source/emacs/lisp/org/oc-basic
/home/wurfkreuz/.emacs.d/straight/build/org/ob hides /home/wurfkreuz/.source/emacs/lisp/org/ob
/home/wurfkreuz/.emacs.d/straight/build/org/ob-tangle hides /home/wurfkreuz/.source/emacs/lisp/org/ob-tangle
/home/wurfkreuz/.emacs.d/straight/build/org/ob-table hides /home/wurfkreuz/.source/emacs/lisp/org/ob-table
/home/wurfkreuz/.emacs.d/straight/build/org/ob-sqlite hides /home/wurfkreuz/.source/emacs/lisp/org/ob-sqlite
/home/wurfkreuz/.emacs.d/straight/build/org/ob-sql hides /home/wurfkreuz/.source/emacs/lisp/org/ob-sql
/home/wurfkreuz/.emacs.d/straight/build/org/ob-shell hides /home/wurfkreuz/.source/emacs/lisp/org/ob-shell
/home/wurfkreuz/.emacs.d/straight/build/org/ob-sed hides /home/wurfkreuz/.source/emacs/lisp/org/ob-sed
/home/wurfkreuz/.emacs.d/straight/build/org/ob-screen hides /home/wurfkreuz/.source/emacs/lisp/org/ob-screen
/home/wurfkreuz/.emacs.d/straight/build/org/ob-scheme hides /home/wurfkreuz/.source/emacs/lisp/org/ob-scheme
/home/wurfkreuz/.emacs.d/straight/build/org/ob-sass hides /home/wurfkreuz/.source/emacs/lisp/org/ob-sass
/home/wurfkreuz/.emacs.d/straight/build/org/ob-ruby hides /home/wurfkreuz/.source/emacs/lisp/org/ob-ruby
/home/wurfkreuz/.emacs.d/straight/build/org/ob-ref hides /home/wurfkreuz/.source/emacs/lisp/org/ob-ref
/home/wurfkreuz/.emacs.d/straight/build/org/ob-python hides /home/wurfkreuz/.source/emacs/lisp/org/ob-python
/home/wurfkreuz/.emacs.d/straight/build/org/ob-processing hides /home/wurfkreuz/.source/emacs/lisp/org/ob-processing
/home/wurfkreuz/.emacs.d/straight/build/org/ob-plantuml hides /home/wurfkreuz/.source/emacs/lisp/org/ob-plantuml
/home/wurfkreuz/.emacs.d/straight/build/org/ob-perl hides /home/wurfkreuz/.source/emacs/lisp/org/ob-perl
/home/wurfkreuz/.emacs.d/straight/build/org/ob-org hides /home/wurfkreuz/.source/emacs/lisp/org/ob-org
/home/wurfkreuz/.emacs.d/straight/build/org/ob-octave hides /home/wurfkreuz/.source/emacs/lisp/org/ob-octave
/home/wurfkreuz/.emacs.d/straight/build/org/ob-ocaml hides /home/wurfkreuz/.source/emacs/lisp/org/ob-ocaml
/home/wurfkreuz/.emacs.d/straight/build/org/ob-maxima hides /home/wurfkreuz/.source/emacs/lisp/org/ob-maxima
/home/wurfkreuz/.emacs.d/straight/build/org/ob-matlab hides /home/wurfkreuz/.source/emacs/lisp/org/ob-matlab
/home/wurfkreuz/.emacs.d/straight/build/org/ob-makefile hides /home/wurfkreuz/.source/emacs/lisp/org/ob-makefile
/home/wurfkreuz/.emacs.d/straight/build/org/ob-lua hides /home/wurfkreuz/.source/emacs/lisp/org/ob-lua
/home/wurfkreuz/.emacs.d/straight/build/org/ob-lob hides /home/wurfkreuz/.source/emacs/lisp/org/ob-lob
/home/wurfkreuz/.emacs.d/straight/build/org/ob-lisp hides /home/wurfkreuz/.source/emacs/lisp/org/ob-lisp
/home/wurfkreuz/.emacs.d/straight/build/org/ob-lilypond hides /home/wurfkreuz/.source/emacs/lisp/org/ob-lilypond
/home/wurfkreuz/.emacs.d/straight/build/org/ob-latex hides /home/wurfkreuz/.source/emacs/lisp/org/ob-latex
/home/wurfkreuz/.emacs.d/straight/build/org/ob-julia hides /home/wurfkreuz/.source/emacs/lisp/org/ob-julia
/home/wurfkreuz/.emacs.d/straight/build/org/ob-js hides /home/wurfkreuz/.source/emacs/lisp/org/ob-js
/home/wurfkreuz/.emacs.d/straight/build/org/ob-java hides /home/wurfkreuz/.source/emacs/lisp/org/ob-java
/home/wurfkreuz/.emacs.d/straight/build/org/ob-haskell hides /home/wurfkreuz/.source/emacs/lisp/org/ob-haskell
/home/wurfkreuz/.emacs.d/straight/build/org/ob-groovy hides /home/wurfkreuz/.source/emacs/lisp/org/ob-groovy
/home/wurfkreuz/.emacs.d/straight/build/org/ob-gnuplot hides /home/wurfkreuz/.source/emacs/lisp/org/ob-gnuplot
/home/wurfkreuz/.emacs.d/straight/build/org/ob-fortran hides /home/wurfkreuz/.source/emacs/lisp/org/ob-fortran
/home/wurfkreuz/.emacs.d/straight/build/org/ob-forth hides /home/wurfkreuz/.source/emacs/lisp/org/ob-forth
/home/wurfkreuz/.emacs.d/straight/build/org/ob-exp hides /home/wurfkreuz/.source/emacs/lisp/org/ob-exp
/home/wurfkreuz/.emacs.d/straight/build/org/ob-eval hides /home/wurfkreuz/.source/emacs/lisp/org/ob-eval
/home/wurfkreuz/.emacs.d/straight/build/org/ob-eshell hides /home/wurfkreuz/.source/emacs/lisp/org/ob-eshell
/home/wurfkreuz/.emacs.d/straight/build/org/ob-emacs-lisp hides /home/wurfkreuz/.source/emacs/lisp/org/ob-emacs-lisp
/home/wurfkreuz/.emacs.d/straight/build/org/ob-dot hides /home/wurfkreuz/.source/emacs/lisp/org/ob-dot
/home/wurfkreuz/.emacs.d/straight/build/org/ob-ditaa hides /home/wurfkreuz/.source/emacs/lisp/org/ob-ditaa
/home/wurfkreuz/.emacs.d/straight/build/org/ob-css hides /home/wurfkreuz/.source/emacs/lisp/org/ob-css
/home/wurfkreuz/.emacs.d/straight/build/org/ob-core hides /home/wurfkreuz/.source/emacs/lisp/org/ob-core
/home/wurfkreuz/.emacs.d/straight/build/org/ob-comint hides /home/wurfkreuz/.source/emacs/lisp/org/ob-comint
/home/wurfkreuz/.emacs.d/straight/build/org/ob-clojure hides /home/wurfkreuz/.source/emacs/lisp/org/ob-clojure
/home/wurfkreuz/.emacs.d/straight/build/org/ob-calc hides /home/wurfkreuz/.source/emacs/lisp/org/ob-calc
/home/wurfkreuz/.emacs.d/straight/build/org/ob-awk hides /home/wurfkreuz/.source/emacs/lisp/org/ob-awk
/home/wurfkreuz/.emacs.d/straight/build/org/ob-R hides /home/wurfkreuz/.source/emacs/lisp/org/ob-R
/home/wurfkreuz/.emacs.d/straight/build/org/ob-C hides /home/wurfkreuz/.source/emacs/lisp/org/ob-C
/home/wurfkreuz/.emacs.d/straight/build/org/ol hides /home/wurfkreuz/.source/emacs/lisp/org/ol
/home/wurfkreuz/.emacs.d/straight/build/org/oc hides /home/wurfkreuz/.source/emacs/lisp/org/oc
/home/wurfkreuz/.emacs.d/straight/build/org/org-element hides /home/wurfkreuz/.source/emacs/lisp/org/org-element
/home/wurfkreuz/.emacs.d/straight/build/org/org-macro hides /home/wurfkreuz/.source/emacs/lisp/org/org-macro
/home/wurfkreuz/.emacs.d/straight/build/org/ox-texinfo hides /home/wurfkreuz/.source/emacs/lisp/org/ox-texinfo
/home/wurfkreuz/.emacs.d/straight/build/org/ox hides /home/wurfkreuz/.source/emacs/lisp/org/ox
/home/wurfkreuz/.emacs.d/straight/build/org/org-version hides /home/wurfkreuz/.source/emacs/lisp/org/org-version
/home/wurfkreuz/.emacs.d/straight/build/map/map hides /home/wurfkreuz/.source/emacs/lisp/emacs-lisp/map
/home/wurfkreuz/.emacs.d/straight/build/compat/compat hides /home/wurfkreuz/.source/emacs/lisp/emacs-lisp/compat
/home/wurfkreuz/.emacs.d/straight/build/seq/seq hides /home/wurfkreuz/.source/emacs/lisp/emacs-lisp/seq
/home/wurfkreuz/.emacs.d/straight/build/eldoc/eldoc hides /home/wurfkreuz/.source/emacs/lisp/emacs-lisp/eldoc

Features:
(shadow sort mail-extr emacsbug ido windmove cc-awk lsp-zig lsp-yang
lsp-yaml lsp-xml lsp-wgsl lsp-volar lsp-vimscript lsp-vhdl lsp-vetur
lsp-html lsp-verilog lsp-vala lsp-v lsp-typeprof lsp-ttcn3 lsp-trunk
lsp-toml lsp-tilt lsp-tex lsp-terraform lsp-svelte lsp-steep lsp-sqls
lsp-sql lsp-sorbet lsp-solidity lsp-solargraph lsp-semgrep lsp-rust
lsp-ruff-lsp lsp-ruby-syntax-tree lsp-ruby-lsp lsp-rubocop lsp-roslyn
lsp-rf lsp-remark lsp-racket lsp-r lsp-qml lsp-pylsp lsp-pyls lsp-pwsh
lsp-purescript lsp-pls lsp-php lsp-perlnavigator lsp-perl lsp-openscad
lsp-ocaml lsp-nushell lsp-nix lsp-nim lsp-nginx lsp-move lsp-mojo
lsp-mint lsp-meson lsp-mdx lsp-marksman lsp-markdown lsp-magik lsp-lua
lsp-lisp lsp-kotlin lsp-json lsp-jq lsp-javascript lsp-idris lsp-haxe
lsp-hack lsp-groovy lsp-graphql lsp-golangci-lint lsp-glsl lsp-gleam
lsp-gdscript lsp-fsharp lsp-fortran lsp-eslint lsp-erlang lsp-emmet
lsp-elm lsp-elixir lsp-earthly lsp-dockerfile lsp-dhall lsp-d lsp-cypher
lsp-cucumber lsp-css lsp-csharp lsp-crystal lsp-credo lsp-cobol
lsp-cmake lsp-clojure lsp-clangd lsp-bufls lsp-go lsp-completion
lsp-beancount lsp-bash lsp-awk lsp-autotools lsp-astro lsp-asm
lsp-ansible lsp-angular lsp-ada lsp-semantic-tokens lsp-actionscript
python flymake-shellcheck crontab-mode js c-ts-common cc-mode cc-fonts
cc-guess cc-menus cc-cmds cc-styles cc-align cc-engine image-file
image-converter org-indent toc-org em-unix em-term em-script em-pred
em-ls em-hist em-glob em-extpipe em-basic em-banner toc-org-autoloads
org-bullets org-bullets-autoloads org-tempo tempo org-drill persist
org-agenda org-drill-autoloads persist-autoloads org-download org-attach
org-download-autoloads lsp-ui-autoloads lsp-pyright lsp-mode
lsp-protocol tree-widget network-stream markdown-mode ht ewoc
lsp-pyright-autoloads lsp-mode-autoloads eldoc-autoloads
markdown-mode-autoloads ht-autoloads ansible ansible-autoloads
haskell-mode haskell-cabal haskell-utils haskell-font-lock
haskell-indentation haskell-string haskell-sort-imports haskell-lexeme
haskell-align-imports haskell-complete-module haskell-ghc-support
flymake-proc dabbrev haskell-customize haskell-mode-autoloads
dockerfile-mode dockerfile-mode-autoloads terraform-mode hcl-mode
terraform-mode-autoloads hcl-mode-autoloads lua-mode lua-mode-autoloads
go-mode find-file ffap etags fileloop go-mode-autoloads raku-mode
raku-repl raku-imenu raku-indent raku-font-lock raku-detect
raku-mode-autoloads flymake-shellcheck-autoloads flymake-hadolint
flymake flymake-hadolint-autoloads pyvenv evil-collection-eshell eshell
pyvenv-autoloads shackle shackle-autoloads popper-echo popper
popper-autoloads vertico-posframe vertico-multiform vertico posframe
vertico-posframe-autoloads vertico-autoloads posframe-autoloads
transpose-frame transpose-frame-autoloads evil-terminal-cursor-changer
evil-terminal-cursor-changer-autoloads em-tramp
eshell-syntax-highlighting em-prompt em-alias
eshell-syntax-highlighting-autoloads hydra lv hydra-autoloads
lv-autoloads helpful cc-langs cc-vars cc-defs trace cl-print edebug
debug backtrace info-look help-fns radix-tree elisp-refs
helpful-autoloads elisp-refs-autoloads fzf fzf-autoloads systemd
conf-mode systemd-autoloads emacs-crontab-mode-autoloads with-editor
server with-editor-autoloads all-the-icons-ivy-rich ivy-rich counsel
swiper evil-collection-ivy ivy delsel ivy-faces ivy-overlay colir
all-the-icons-ivy-rich-autoloads ivy-rich-autoloads counsel-autoloads
swiper-autoloads ivy-autoloads embark-autoloads use-package-bind-key
bind-key mentor url-scgi mentor-rpc mentor-files mentor-data xml-rpc
url-http url-auth url-gw nsm evil-collection-term term disp-table ehelp
mentor-autoloads url-scgi-autoloads xml-rpc-autoloads projectile
projectile-autoloads cider-autoloads cider package url-handlers tramp-sh
cider-debug cider-browse-ns cider-mode cider-xref-backend cider-find
cider-inspector cider-completion cider-profile cider-eval cider-jar
arc-mode archive-mode cider-repl-history pulse cider-repl cider-resolve
cider-test cider-overlays cider-stacktrace cider-doc cider-browse-spec
cider-clojuredocs cider-eldoc cider-docstring cider-client cider-common
xref project cider-completion-context cider-connection cider-popup
sesman-browser nrepl-client cider-util color sesman nrepl-dict spinner
clojure-mode lisp-mnt align imenu parseedn parseclj-parser parseclj-lex
parseclj-alist sesman-autoloads spinner-autoloads parseedn-autoloads
map-autoloads parseclj-autoloads clojure-mode-autoloads zoxide-autoloads
paredit paredit-autoloads sudo-edit sudo-edit-autoloads
exec-path-from-shell exec-path-from-shell-autoloads fish-completion
em-cmpl em-dirs esh-mode esh-var esh-cmd esh-ext esh-opt esh-proc esh-io
esh-arg esh-module esh-groups esh-util fish-completion-autoloads cape
cape-autoloads corfu-popupinfo corfu-history corfu-echo corfu
corfu-autoloads orderless orderless-autoloads yasnippet
yasnippet-autoloads vimish-fold f vimish-fold-autoloads f-autoloads
evil-collection-docker docker docker-context docker-volume
docker-network docker-image docker-container docker-faces docker-core
docker-compose docker-process docker-utils tablist tablist-filter
semantic/wisent/comp semantic/wisent semantic/wisent/wisent
semantic/util-modes semantic/util semantic semantic/tag semantic/lex
semantic/fw mode-local cedet docker-group dash aio s docker-autoloads
tablist-autoloads dash-autoloads aio-autoloads circe lui-irc-colors irc
lcs lui-logging lui-format lui tracking shorten flyspell ispell
circe-compat circe-autoloads xterm-color xterm-color-autoloads rg vc
rg-info-hack rg-menu rg-ibuffer rg-result wgrep-rg wgrep rg-history
rg-header ibuf-ext evil-collection-ibuffer ibuffer ibuffer-loaddefs grep
compile cus-edit pp cus-load rg-autoloads wgrep-autoloads transient
compat transient-autoloads which-key which-key-autoloads dired-async
dired-aux async async-autoloads avy avy-autoloads daemons tramp trampver
tramp-integration files-x tramp-message tramp-compat shell
tramp-loaddefs daemons-autoloads compat-autoloads seq-autoloads
s-autoloads general general-autoloads clojure-ts-mode
clojure-ts-mode-autoloads treesit-auto treesit-auto-autoloads
all-the-icons-dired all-the-icons-dired-autoloads all-the-icons
all-the-icons-faces data-material data-weathericons data-octicons
data-fileicons data-faicons data-alltheicons all-the-icons-autoloads
use-package-ensure rose-pine-theme evil-collection-unimpaired
evil-collection-minibuffer evil-collection-org evil-collection-dired
evil-collection annalist evil-collection-autoloads annalist-autoloads
evil-org-agenda evil-org evil-org-autoloads evil-surround
evil-surround-autoloads evil evil-integration evil-maps evil-commands
evil-digraphs pcase reveal evil-jumps evil-command-window evil-types
evil-search evil-ex evil-macros evil-repeat evil-states evil-core advice
evil-common rect evil-vars edmacro kmacro evil-autoloads
goto-chg-autoloads undo-tree diff queue undo-tree-autoloads
queue-autoloads finder-inf use-package-core diary-lib diary-loaddefs
midnight autorevert pixel-scroll cua-base saveplace desktop frameset
savehist comp comp-cstr warnings comp-run comp-common elec-pair
display-line-numbers vc-git diff-mode track-changes easy-mmode
vc-dispatcher oc-basic org-element org-persist org-id org-refile
org-element-ast inline avl-tree generator ol-eww eww xdg url-queue
mm-url ol-rmail ol-mhe ol-irc ol-info ol-gnus nnselect gnus-art mm-uu
mml2015 mm-view mml-smime smime gnutls dig gnus-sum shr pixel-fill
kinsoku url-file svg dom gnus-group gnus-undo gnus-start gnus-dbus dbus
xml gnus-cloud nnimap nnmail browse-url url url-proxy url-privacy
url-expand url-methods url-history url-cookie generate-lisp-file
url-domsuf url-util url-parse auth-source eieio eieio-core json map
byte-opt url-vars mail-source utf7 nnoo parse-time gnus-spec gnus-int
gnus-range message sendmail mailcap yank-media puny rfc822 mml mml-sec
password-cache epa derived epg rfc6068 epg-config mm-decode mm-bodies
mm-encode mail-parse rfc2231 rfc2047 rfc2045 ietf-drums mailabbrev
gmm-utils mailheader gnus-win gnus nnheader gnus-util
text-property-search mail-utils range mm-util mail-prsvr wid-edit
ol-docview doc-view filenotify jka-compr image-mode exif dired
dired-loaddefs ol-bibtex bibtex iso8601 ol-bbdb ol-w3m ol-doi
org-link-doi org ob ob-tangle ob-ref ob-lob ob-table ob-exp org-macro
org-src sh-script smie treesit executable ob-comint org-pcomplete
pcomplete comint ansi-osc ansi-color ring org-list org-footnote
org-faces org-entities time-date noutline outline icons ob-emacs-lisp
ob-core ob-eval org-cycle org-table ol rx org-fold org-fold-core
org-keys oc org-loaddefs thingatpt find-func cal-menu calendar
cal-loaddefs org-version org-compat org-macs format-spec
use-package-autoloads info bind-key-autoloads straight-autoloads cl-seq
cl-extra help-mode straight subr-x cl-macs gv cl-loaddefs cl-lib
bytecomp byte-compile 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 touch-screen 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 xwidget-internal dbusbind
inotify lcms2 dynamic-setting system-font-setting font-render-setting
cairo gtk x-toolkit xinput2 x multi-tty move-toolbar
make-network-process native-compile emacs)

Memory information:
((conses 16 2050046 1227782) (symbols 48 77508 109) (strings 32 384839 31305)
(string-bytes 1 11146626) (vectors 16 138734) (vector-slots 8 2475924 266182)
(floats 8 1375 6543) (intervals 56 179458 5628) (buffers 992 38))
[Message part 2 (text/html, inline)]
[image_2024-07-14_22-03-00.png (image/png, attachment)]
[image_2024-07-14_22-29-50.png (image/png, attachment)]

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#72117; Package emacs. (Mon, 15 Jul 2024 01:03:02 GMT) Full text and rfc822 format available.

Message #8 received at 72117 <at> debbugs.gnu.org (full text, mbox):

From: Jim Porter <jporterbugs <at> gmail.com>
To: the_wurfkreuz <the_wurfkreuz <at> proton.me>, 72117 <at> debbugs.gnu.org
Subject: Re: bug#72117: Command doesn't execute correctly in eshell
Date: Sun, 14 Jul 2024 18:01:09 -0700
[Message part 1 (text/plain, inline)]
On 7/14/2024 12:33 PM, the_wurfkreuz via Bug reports for GNU Emacs, the 
Swiss army knife of text editors wrote:
> First of all, i can't execute 'sudo lsof | grep delete | head -10' in
> eshell.

'sudo -S' should help here: it'll output the sudo password prompt on 
stderr so that Eshell can see it and handle password entry. (You should 
be able to enter your password anyway, but without the -S it would just 
be echoed to the screen.)

 But that's not the most interesting part. I can execute the
> command with 'eshell/sudo'. But after the command execution emacs will
> take the whole CPU processing time if i have 
> '(global-display-line-numbers-mode 1)'
> option enabled.

I can't reproduce this particular issue, but I can reproduce *an* issue. 
It seems to be due to "head -10" exiting early (as it should), which 
results in a broken pipe. However, Eshell's broken pipe handling wasn't 
properly cleaning up the process ("grep" in this example).
[0001-Use-kill-process-as-a-fallback-when-a-pipe-gets-brok.patch (text/plain, attachment)]

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#72117; Package emacs. (Tue, 16 Jul 2024 03:11:01 GMT) Full text and rfc822 format available.

Message #11 received at 72117 <at> debbugs.gnu.org (full text, mbox):

From: Jim Porter <jporterbugs <at> gmail.com>
To: the_wurfkreuz <the_wurfkreuz <at> proton.me>, 72117 <at> debbugs.gnu.org
Subject: Re: bug#72117: Command doesn't execute correctly in eshell
Date: Mon, 15 Jul 2024 20:09:26 -0700
[Message part 1 (text/plain, inline)]
On 7/14/2024 6:01 PM, Jim Porter wrote:
> On 7/14/2024 12:33 PM, the_wurfkreuz via Bug reports for GNU Emacs, the 
> Swiss army knife of text editors wrote:
>> First of all, i can't execute 'sudo lsof | grep delete | head -10' in
>> eshell.
> 
> 'sudo -S' should help here: it'll output the sudo password prompt on 
> stderr so that Eshell can see it and handle password entry. (You should 
> be able to enter your password anyway, but without the -S it would just 
> be echoed to the screen.)
> 
>   But that's not the most interesting part. I can execute the
>> command with 'eshell/sudo'. But after the command execution emacs will
>> take the whole CPU processing time if i have 
>> '(global-display-line-numbers-mode 1)'
>> option enabled.
> 
> I can't reproduce this particular issue, but I can reproduce *an* issue. 
> It seems to be due to "head -10" exiting early (as it should), which 
> results in a broken pipe. However, Eshell's broken pipe handling wasn't 
> properly cleaning up the process ("grep" in this example).

Here's a better patch, based on the recent improvements to Tramp in 
bug#72013.
[0001-Handle-broken-pipes-in-a-better-way-in-Eshell.patch (text/plain, attachment)]

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#72117; Package emacs. (Wed, 17 Jul 2024 02:11:02 GMT) Full text and rfc822 format available.

Message #14 received at 72117 <at> debbugs.gnu.org (full text, mbox):

From: Jim Porter <jporterbugs <at> gmail.com>
To: the_wurfkreuz <the_wurfkreuz <at> proton.me>
Cc: 72117 <at> debbugs.gnu.org
Subject: Re: bug#72117: Command doesn't execute correctly in eshell
Date: Tue, 16 Jul 2024 19:09:32 -0700
(Don't forget to Reply All so that Debbugs is CCed in your message, or
else the tracker won't see your messages.)

On Tue, Jul 16, 2024 at 2:14 AM the_wurfkreuz <the_wurfkreuz <at> proton.me> wrote:
>
> I updated Emacs and used your latest patch. The problem with pipe is fixed as far as i can understand, but my original problem with executing the command through tramp (eshell/sudo) is still there, though it's elusive and hard to reproduce. Right now, i can't reproduce it launching bare Emacs (emacs -Q). And with my current config i was getting it around 50/50 of the time. When i got it, i had this message: 'error in process filter: Forbidden reentrant call of Tramp'.

After testing some more locally, I notice that too. Digging further,
this problem is actually multifaceted, and fixing all the different
issues I've uncovered would be too risky for Emacs 30. Does the first
patch I posted work for you? That's a lot simpler, and should be safe
enough for Emacs 30; then I can make more extensive fixes for Emacs
31.

(The "Forbidden reentrant call of Tramp" is likely occurring when
calling 'signal-process' on the "lsof" command, which could happen if
some Tramp code is above us in the stack; in that case,
'signal-process' would reenter Tramp code, and then Tramp bails out
just to be safe.)




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#72117; Package emacs. (Thu, 18 Jul 2024 05:07:01 GMT) Full text and rfc822 format available.

Message #17 received at 72117 <at> debbugs.gnu.org (full text, mbox):

From: Jim Porter <jporterbugs <at> gmail.com>
To: the_wurfkreuz <the_wurfkreuz <at> proton.me>
Cc: 72117 <at> debbugs.gnu.org
Subject: Re: bug#72117: Command doesn't execute correctly in eshell
Date: Wed, 17 Jul 2024 22:05:38 -0700
[Message part 1 (text/plain, inline)]
On 7/16/2024 7:09 PM, Jim Porter wrote:
> After testing some more locally, I notice that too. Digging further,
> this problem is actually multifaceted, and fixing all the different
> issues I've uncovered would be too risky for Emacs 30. Does the first
> patch I posted work for you? That's a lot simpler, and should be safe
> enough for Emacs 30; then I can make more extensive fixes for Emacs
> 31.

I think the attached patches would work for Emacs 31, but are almost 
certainly too risky for Emacs 30. The first one especially changes some 
very fundamental parts of Eshell, though happily in a way that 
simplifies it a bit overall.

The original patch I posted is probably the safest for Emacs 30, since 
it's only a slight tweak to how we kill processes when their output pipe 
breaks.
[0001-Improve-handling-of-deferrable-Eshell-commands.patch (text/plain, attachment)]
[0002-Handle-broken-pipes-in-a-better-way-in-Eshell.patch (text/plain, attachment)]

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#72117; Package emacs. (Thu, 18 Jul 2024 09:32:02 GMT) Full text and rfc822 format available.

Message #20 received at 72117 <at> debbugs.gnu.org (full text, mbox):

From: Michael Albinus <michael.albinus <at> gmx.de>
To: Jim Porter <jporterbugs <at> gmail.com>
Cc: the_wurfkreuz <the_wurfkreuz <at> proton.me>, 72117 <at> debbugs.gnu.org
Subject: Re: bug#72117: Command doesn't execute correctly in eshell
Date: Thu, 18 Jul 2024 11:31:09 +0200
Jim Porter <jporterbugs <at> gmail.com> writes:

Hi Jim,

> diff --git a/lisp/eshell/esh-proc.el b/lisp/eshell/esh-proc.el
> index 0dcdf3bb76c..fbeb13362f3 100644
> --- a/lisp/eshell/esh-proc.el
> +++ b/lisp/eshell/esh-proc.el
> +                   (cond
> +                    ;; Delay signalling remote processes to prevent
> +                    ;; "Forbidden reentrant call of Tramp".
> +                    ((process-get proc 'remote-pid)
> +                     (run-at-time 0 nil #'signal-process proc 'SIGPIPE))

Shouldn't there be a non-nil REMOTE argument?

Best regards, Michael.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#72117; Package emacs. (Thu, 18 Jul 2024 15:41:02 GMT) Full text and rfc822 format available.

Message #23 received at 72117 <at> debbugs.gnu.org (full text, mbox):

From: Jim Porter <jporterbugs <at> gmail.com>
To: Michael Albinus <michael.albinus <at> gmx.de>
Cc: the_wurfkreuz <the_wurfkreuz <at> proton.me>, 72117 <at> debbugs.gnu.org
Subject: Re: bug#72117: Command doesn't execute correctly in eshell
Date: Thu, 18 Jul 2024 08:38:53 -0700
On 7/18/2024 2:31 AM, Michael Albinus via Bug reports for GNU Emacs, the 
Swiss army knife of text editors wrote:
> Jim Porter <jporterbugs <at> gmail.com> writes:
> 
>> diff --git a/lisp/eshell/esh-proc.el b/lisp/eshell/esh-proc.el
>> index 0dcdf3bb76c..fbeb13362f3 100644
>> --- a/lisp/eshell/esh-proc.el
>> +++ b/lisp/eshell/esh-proc.el
>> +                   (cond
>> +                    ;; Delay signalling remote processes to prevent
>> +                    ;; "Forbidden reentrant call of Tramp".
>> +                    ((process-get proc 'remote-pid)
>> +                     (run-at-time 0 nil #'signal-process proc 'SIGPIPE))
> 
> Shouldn't there be a non-nil REMOTE argument?

Isn't a process object with the 'remote-pid' property set sufficient 
here? From my understanding of the code, REMOTE is redundant in that case.

(I'll probably need the REMOTE argument in some other Eshell code that 
we've been discussing recently, but not here I think...)




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#72117; Package emacs. (Thu, 18 Jul 2024 16:50:02 GMT) Full text and rfc822 format available.

Message #26 received at 72117 <at> debbugs.gnu.org (full text, mbox):

From: Michael Albinus <michael.albinus <at> gmx.de>
To: Jim Porter <jporterbugs <at> gmail.com>
Cc: the_wurfkreuz <the_wurfkreuz <at> proton.me>, 72117 <at> debbugs.gnu.org
Subject: Re: bug#72117: Command doesn't execute correctly in eshell
Date: Thu, 18 Jul 2024 18:49:42 +0200
Jim Porter <jporterbugs <at> gmail.com> writes:

Hi Jim,

>>> diff --git a/lisp/eshell/esh-proc.el b/lisp/eshell/esh-proc.el
>>> index 0dcdf3bb76c..fbeb13362f3 100644
>>> --- a/lisp/eshell/esh-proc.el
>>> +++ b/lisp/eshell/esh-proc.el
>>> +                   (cond
>>> +                    ;; Delay signalling remote processes to prevent
>>> +                    ;; "Forbidden reentrant call of Tramp".
>>> +                    ((process-get proc 'remote-pid)
>>> +                     (run-at-time 0 nil #'signal-process proc 'SIGPIPE))
>> Shouldn't there be a non-nil REMOTE argument?
>
> Isn't a process object with the 'remote-pid' property set sufficient
> here? From my understanding of the code, REMOTE is redundant in that
> case.

You're right, I've misremembered. Sorry for the noise.

Best regards, Michael.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#72117; Package emacs. (Thu, 18 Jul 2024 18:28:01 GMT) Full text and rfc822 format available.

Message #29 received at 72117 <at> debbugs.gnu.org (full text, mbox):

From: Jim Porter <jporterbugs <at> gmail.com>
To: Michael Albinus <michael.albinus <at> gmx.de>
Cc: the_wurfkreuz <the_wurfkreuz <at> proton.me>, 72117 <at> debbugs.gnu.org
Subject: Re: bug#72117: Command doesn't execute correctly in eshell
Date: Thu, 18 Jul 2024 11:26:27 -0700
On 7/18/2024 9:49 AM, Michael Albinus via Bug reports for GNU Emacs, the 
Swiss army knife of text editors wrote:
> You're right, I've misremembered. Sorry for the noise.

No worries! Merged these patches to the master branch as c7a498260ce. 
Leaving this open to handle the release branch side. If there's anything 
still broken on the master branch, I can merge some followups, but the 
existing patches should improve matters in Eshell generally.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#72117; Package emacs. (Sat, 27 Jul 2024 05:20:02 GMT) Full text and rfc822 format available.

Message #32 received at 72117 <at> debbugs.gnu.org (full text, mbox):

From: Jim Porter <jporterbugs <at> gmail.com>
To: the_wurfkreuz <the_wurfkreuz <at> proton.me>, 72117 <at> debbugs.gnu.org
Cc: eliz <at> gnu.org
Subject: Re: bug#72117: Command doesn't execute correctly in eshell
Date: Fri, 26 Jul 2024 22:18:22 -0700
[Message part 1 (text/plain, inline)]
On 7/14/2024 6:01 PM, Jim Porter wrote:
> On 7/14/2024 12:33 PM, the_wurfkreuz via Bug reports for GNU Emacs, the 
> Swiss army knife of text editors wrote:
>   But that's not the most interesting part. I can execute the
>> command with 'eshell/sudo'. But after the command execution emacs will
>> take the whole CPU processing time if i have 
>> '(global-display-line-numbers-mode 1)'
>> option enabled.
> 
> I can't reproduce this particular issue, but I can reproduce *an* issue. 
> It seems to be due to "head -10" exiting early (as it should), which 
> results in a broken pipe. However, Eshell's broken pipe handling wasn't 
> properly cleaning up the process ("grep" in this example).

Eli, would this patch (re-attached here) be ok for Emacs 30? It's not a 
perfect solution (the fix currently on master is much better), but it's 
the least-risky change to this code that I could make, and it should 
improve matters somewhat for the release branch.

To summarize the problem so you have a bit more context for what this is 
changing: in Eshell, if you have a pipeline like "cat some-file | head 
-10", then the "head" process can exit early and raise an 
'eshell-pipe-broken' signal. The process filter for "cat" will catch 
this signal and try to send SIGPIPE to the actual "cat" process. 
However, for MS-Windows (which doesn't have SIGPIPE), and Tramp (where I 
couldn't get 'signal-process' to work due to another bug[1]), it just 
deletes the process. Unfortunately, that was failing to clean up the 
stderr "process" object, which caused Eshell to think the command wasn't 
complete. By changing to 'kill-process', this cleanup happens and things 
work more smoothly.

If you'd prefer to leave it as-is on Emacs 30, I don't mind either. This 
bug has been present since 29.1, and it took quite a while for anyone to 
notice it, so it probably doesn't come up terribly often.

[1] This is now fixed.
[0001-Use-kill-process-as-a-fallback-when-a-pipe-gets-brok.patch (text/plain, attachment)]

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#72117; Package emacs. (Sat, 27 Jul 2024 06:41:02 GMT) Full text and rfc822 format available.

Message #35 received at 72117 <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: Jim Porter <jporterbugs <at> gmail.com>
Cc: the_wurfkreuz <at> proton.me, 72117 <at> debbugs.gnu.org
Subject: Re: bug#72117: Command doesn't execute correctly in eshell
Date: Sat, 27 Jul 2024 09:40:10 +0300
> Date: Fri, 26 Jul 2024 22:18:22 -0700
> From: Jim Porter <jporterbugs <at> gmail.com>
> Cc: eliz <at> gnu.org
> 
> On 7/14/2024 6:01 PM, Jim Porter wrote:
> > On 7/14/2024 12:33 PM, the_wurfkreuz via Bug reports for GNU Emacs, the 
> > Swiss army knife of text editors wrote:
> >   But that's not the most interesting part. I can execute the
> >> command with 'eshell/sudo'. But after the command execution emacs will
> >> take the whole CPU processing time if i have 
> >> '(global-display-line-numbers-mode 1)'
> >> option enabled.
> > 
> > I can't reproduce this particular issue, but I can reproduce *an* issue. 
> > It seems to be due to "head -10" exiting early (as it should), which 
> > results in a broken pipe. However, Eshell's broken pipe handling wasn't 
> > properly cleaning up the process ("grep" in this example).
> 
> Eli, would this patch (re-attached here) be ok for Emacs 30? It's not a 
> perfect solution (the fix currently on master is much better), but it's 
> the least-risky change to this code that I could make, and it should 
> improve matters somewhat for the release branch.

This is okay for emacs-30, thanks.




Reply sent to Jim Porter <jporterbugs <at> gmail.com>:
You have taken responsibility. (Sat, 27 Jul 2024 19:16:02 GMT) Full text and rfc822 format available.

Notification sent to the_wurfkreuz <the_wurfkreuz <at> proton.me>:
bug acknowledged by developer. (Sat, 27 Jul 2024 19:16:02 GMT) Full text and rfc822 format available.

Message #40 received at 72117-done <at> debbugs.gnu.org (full text, mbox):

From: Jim Porter <jporterbugs <at> gmail.com>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: 72117-done <at> debbugs.gnu.org, the_wurfkreuz <at> proton.me
Subject: Re: bug#72117: Command doesn't execute correctly in eshell
Date: Sat, 27 Jul 2024 12:14:15 -0700
On 7/26/2024 11:40 PM, Eli Zaretskii wrote:
> This is okay for emacs-30, thanks.

Thanks. Merged to the release branch as 469bc7c9686, and closing this 
bug now.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#72117; Package emacs. (Sun, 28 Jul 2024 08:02:02 GMT) Full text and rfc822 format available.

Message #43 received at 72117 <at> debbugs.gnu.org (full text, mbox):

From: Jim Porter <jporterbugs <at> gmail.com>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: the_wurfkreuz <at> proton.me, 72117 <at> debbugs.gnu.org
Subject: Re: bug#72117: Command doesn't execute correctly in eshell
Date: Sun, 28 Jul 2024 00:59:52 -0700
On 7/27/2024 12:14 PM, Jim Porter wrote:
> On 7/26/2024 11:40 PM, Eli Zaretskii wrote:
>> This is okay for emacs-30, thanks.
> 
> Thanks. Merged to the release branch as 469bc7c9686, and closing this 
> bug now.

I just realized that I forgot to add "Do not merge to master" to the 
commit message (this was already fixed in a better way on master). I'm 
not at my development system right now, but if no one else has merged 
from the release branch to master by the time I'm back, hopefully this 
message will help clarify things.

Sorry for forgetting about that.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#72117; Package emacs. (Sun, 28 Jul 2024 16:23:01 GMT) Full text and rfc822 format available.

Message #46 received at 72117 <at> debbugs.gnu.org (full text, mbox):

From: Jim Porter <jporterbugs <at> gmail.com>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: the_wurfkreuz <at> proton.me, 72117 <at> debbugs.gnu.org
Subject: Re: bug#72117: Command doesn't execute correctly in eshell
Date: Sun, 28 Jul 2024 09:21:27 -0700
On 7/28/2024 12:59 AM, Jim Porter wrote:
> I just realized that I forgot to add "Do not merge to master" to the 
> commit message (this was already fixed in a better way on master). I'm 
> not at my development system right now, but if no one else has merged 
> from the release branch to master by the time I'm back, hopefully this 
> message will help clarify things.

I've now performed the merge, so there should (hopefully) be no problems 
with future merges from the release branch.




bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Mon, 26 Aug 2024 11:24:06 GMT) Full text and rfc822 format available.

This bug report was last modified 174 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.