GNU bug report logs - #63189
28.2; Shell commands doesn't get executed after command that use stdin.

Previous Next

Package: emacs;

Reported by: Новогодняя Ёлка <gamemode1.459 <at> gmail.com>

Date: Sun, 30 Apr 2023 14:57:02 UTC

Severity: normal

Found in version 28.2

To reply to this bug, email your comments to 63189 AT debbugs.gnu.org.

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#63189; Package emacs. (Sun, 30 Apr 2023 14:57:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Новогодняя Ёлка <gamemode1.459 <at> gmail.com>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs <at> gnu.org. (Sun, 30 Apr 2023 14:57:02 GMT) Full text and rfc822 format available.

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

From: Новогодняя Ёлка
 <gamemode1.459 <at> gmail.com>
To: "bug-gnu-emacs <at> gnu.org" <bug-gnu-emacs <at> gnu.org>
Subject: 28.2; Shell commands doesn't get executed after command that
 use stdin.
Date: Sun, 30 Apr 2023 13:10:52 +0300
[Message part 1 (text/plain, inline)]
Steps to reproduce:
1. emacs -q
2. M-x shell
3. echo start
sudo pacman -S nyancat
echo end
4. See, that "end" doesn't get printed.

~ > echo start
sudo pacman -S nyancat
echo end
echo start
start
~ > sudo pacman -S nyancat
warning: nyancat-1.5.2-2 is up to date -- reinstalling
resolving dependencies...
looking for conflicting packages...

Package (1) Old Version New Version Net Change
community/nyancat 1.5.2-2 1.5.2-2 0.00 MiB
Total Installed Size: 0.06 MiB
Net Upgrade Size: 0.00 MiB

:: Proceed with installation? [Y/n] y
y
(1/1) checking keys in keyring [####################################################################] 100%
(1/1) checking package integrity [####################################################################] 100%
(1/1) loading package files [####################################################################] 100%
(1/1) checking for file conflicts [####################################################################] 100%
(1/1) checking available disk space [####################################################################] 100%
:: Processing package changes...
(1/1) reinstalling nyancat [####################################################################] 100%
:: Running post-transaction hooks...
(1/2) Reloading system manager configuration...
(2/2) Arming ConditionNeedsUpdate...
~ >

In GNU Emacs 28.2 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.24.36, cairo version 1.17.6)
of 2023-01-03 built on 2
Windowing system distributor 'The X.Org Foundation', version 11.0.12101008
System Description: Arch Linux

Configured using:
'configure --sysconfdir=/etc --prefix=/usr --libexecdir=/usr/lib
--localstatedir=/var --with-cairo --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 THREADS TIFF TOOLKIT_SCROLL_BARS X11 XDBE
XIM XPM GTK3 ZLIB

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

Major mode: Shell
Minor modes in effect:
shell-dirtrack-mode: t
tooltip-mode: t
global-eldoc-mode: t
show-paren-mode: t
electric-indent-mode: t
mouse-wheel-mode: t
tool-bar-mode: t
menu-bar-mode: t
file-name-shadow-mode: t
global-font-lock-mode: t
font-lock-mode: t
blink-cursor-mode: t
auto-composition-mode: t
auto-encryption-mode: t
auto-compression-mode: t
line-number-mode: t
indent-tabs-mode: t
transient-mark-mode: t

Load-path shadows:
None found.

Features:
(shadow sort mail-extr emacsbug message rmc puny dired dired-loaddefs
rfc822 mml mml-sec epa derived epg rfc6068 epg-config gnus-util rmail
rmail-loaddefs auth-source cl-seq eieio eieio-core cl-macs
eieio-loaddefs password-cache json map text-property-search seq byte-opt
gv bytecomp byte-compile cconv mm-decode mm-bodies mm-encode mail-parse
rfc2231 mailabbrev gmm-utils mailheader sendmail rfc2047 rfc2045
ietf-drums mm-util mail-prsvr mail-utils shell pcomplete comint
ansi-color ring time-date subr-x cl-loaddefs cl-lib iso-transl tooltip
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 cl-generic cham georgian
utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao korean
japanese eucjp-ms cp51932 hebrew greek romanian slovak czech european
ethiopic indian cyrillic chinese composite emoji-zwj charscript charprop
case-table epa-hook jka-cmpr-hook help simple abbrev obarray
cl-preloaded nadvice button loaddefs faces cus-face macroexp files
window text-properties overlay sha1 md5 base64 format env code-pages
mule custom widget hashtable-print-readable backquote threads dbusbind
inotify lcms2 dynamic-setting system-font-setting font-render-setting
cairo move-toolbar gtk x-toolkit x multi-tty make-network-process emacs)

Memory information:
((conses 16 64126 11476)
(symbols 48 7189 1)
(strings 32 20848 1844)
(string-bytes 1 694151)
(vectors 16 14694)
(vector-slots 8 196111 12327)
(floats 8 24 36)
(intervals 56 801 1)
(buffers 992 12))

[Message part 2 (text/html, inline)]

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#63189; Package emacs. (Mon, 01 May 2023 07:22:02 GMT) Full text and rfc822 format available.

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

From: Philip Kaludercic <philipk <at> posteo.net>
To: Новогодняя Ёлка
 <gamemode1.459 <at> gmail.com>
Cc: 63189 <at> debbugs.gnu.org
Subject: Re: bug#63189: 28.2; Shell commands doesn't get executed after
 command that use stdin.
Date: Mon, 01 May 2023 07:22:24 +0000
Новогодняя Ёлка <gamemode1.459 <at> gmail.com> writes:

> Steps to reproduce:
> 1. emacs -q
> 2. M-x shell
> 3. echo start
> sudo pacman -S nyancat
> echo end
> 4. See, that "end" doesn't get printed.

Can you confirm that the commands

echo start
sleep 1
echo end

have the same effect?  That would make it easier to test on non-arch
systems, and understand the general issue.

And

echo start
true
echo end

does not?

> ~ > echo start
> sudo pacman -S nyancat
> echo end
> echo start
> start
> ~ > sudo pacman -S nyancat
> warning: nyancat-1.5.2-2 is up to date -- reinstalling
> resolving dependencies...
> looking for conflicting packages...
>
> Package (1) Old Version New Version Net Change
> community/nyancat 1.5.2-2 1.5.2-2 0.00 MiB
> Total Installed Size: 0.06 MiB
> Net Upgrade Size: 0.00 MiB
>
> :: Proceed with installation? [Y/n] y
> y
> (1/1) checking keys in keyring [####################################################################] 100%
> (1/1) checking package integrity [####################################################################] 100%
> (1/1) loading package files [####################################################################] 100%
> (1/1) checking for file conflicts [####################################################################] 100%
> (1/1) checking available disk space [####################################################################] 100%
> :: Processing package changes...
> (1/1) reinstalling nyancat [####################################################################] 100%
> :: Running post-transaction hooks...
> (1/2) Reloading system manager configuration...
> (2/2) Arming ConditionNeedsUpdate...
> ~ >
>
> In GNU Emacs 28.2 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.24.36, cairo version 1.17.6)
> of 2023-01-03 built on 2
> Windowing system distributor 'The X.Org Foundation', version 11.0.12101008
> System Description: Arch Linux
>
> Configured using:
> 'configure --sysconfdir=/etc --prefix=/usr --libexecdir=/usr/lib
> --localstatedir=/var --with-cairo --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 THREADS TIFF TOOLKIT_SCROLL_BARS X11 XDBE
> XIM XPM GTK3 ZLIB
>
> Important settings:
> value of $LANG: en_US.UTF-8
> locale-coding-system: utf-8-unix
>
> Major mode: Shell
> Minor modes in effect:
> shell-dirtrack-mode: t
> tooltip-mode: t
> global-eldoc-mode: t
> show-paren-mode: t
> electric-indent-mode: t
> mouse-wheel-mode: t
> tool-bar-mode: t
> menu-bar-mode: t
> file-name-shadow-mode: t
> global-font-lock-mode: t
> font-lock-mode: t
> blink-cursor-mode: t
> auto-composition-mode: t
> auto-encryption-mode: t
> auto-compression-mode: t
> line-number-mode: t
> indent-tabs-mode: t
> transient-mark-mode: t
>
> Load-path shadows:
> None found.
>
> Features:
> (shadow sort mail-extr emacsbug message rmc puny dired dired-loaddefs
> rfc822 mml mml-sec epa derived epg rfc6068 epg-config gnus-util rmail
> rmail-loaddefs auth-source cl-seq eieio eieio-core cl-macs
> eieio-loaddefs password-cache json map text-property-search seq byte-opt
> gv bytecomp byte-compile cconv mm-decode mm-bodies mm-encode mail-parse
> rfc2231 mailabbrev gmm-utils mailheader sendmail rfc2047 rfc2045
> ietf-drums mm-util mail-prsvr mail-utils shell pcomplete comint
> ansi-color ring time-date subr-x cl-loaddefs cl-lib iso-transl tooltip
> 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 cl-generic cham georgian
> utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao korean
> japanese eucjp-ms cp51932 hebrew greek romanian slovak czech european
> ethiopic indian cyrillic chinese composite emoji-zwj charscript charprop
> case-table epa-hook jka-cmpr-hook help simple abbrev obarray
> cl-preloaded nadvice button loaddefs faces cus-face macroexp files
> window text-properties overlay sha1 md5 base64 format env code-pages
> mule custom widget hashtable-print-readable backquote threads dbusbind
> inotify lcms2 dynamic-setting system-font-setting font-render-setting
> cairo move-toolbar gtk x-toolkit x multi-tty make-network-process emacs)
>
> Memory information:
> ((conses 16 64126 11476)
> (symbols 48 7189 1)
> (strings 32 20848 1844)
> (string-bytes 1 694151)
> (vectors 16 14694)
> (vector-slots 8 196111 12327)
> (floats 8 24 36)
> (intervals 56 801 1)
> (buffers 992 12))




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#63189; Package emacs. (Mon, 01 May 2023 09:19:02 GMT) Full text and rfc822 format available.

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

From: Новогодняя Ёлка
 <gamemode1.459 <at> gmail.com>
To: Philip Kaludercic <philipk <at> posteo.net>
Cc: "63189 <at> debbugs.gnu.org" <63189 <at> debbugs.gnu.org>
Subject: Re: bug#63189: 28.2; Shell commands doesn't get executed after
 command that use stdin.
Date: Mon, 1 May 2023 12:18:28 +0300
[Message part 1 (text/plain, inline)]
> Can you confirm that the commands
> echo start
> sleep 1
> echo end
> have the same effect?

No, it works as it should. Same with true command.
It's just commands that read from the standard input behave that way. (pacman, apt, etc)
1. Create a file named ~/a.sh with content
read -p "Continue (y/n)?" choice
2. chmod +x ~/a.sh
3. emacs -q
4. M-x shell
5. echo start
~/a.sh
echo end

The result is
~ > echo start
~/a.sh
echo end
echo start
start
~ > ~/a.sh
Continue (y/n)?y
y
~ >
[Message part 2 (text/html, inline)]

This bug report was last modified 1 year and 4 days ago.

Previous Next


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