zsh-workers
 help / color / mirror / code / Atom feed
* BUG: Random behavior of the shell
@ 2019-09-29 21:00 Sebastian Gniazdowski
  2019-09-29 22:34 ` Bart Schaefer
  0 siblings, 1 reply; 4+ messages in thread
From: Sebastian Gniazdowski @ 2019-09-29 21:00 UTC (permalink / raw)
  To: Zsh hackers list

[-- Attachment #1: Type: text/plain, Size: 1159 bytes --]

Hello,
I was getting such behavior earlier, but waited with the report. Now
it's a more clear one, so I'm reporting: https://youtu.be/N-HH2f_Rr0E

The list isn't getting filtered. I attach the command that's being
run, it contains the list definition, so anyone can test it. Maybe
someone else will catch this too?

Earlier was: the `quiet=1` assignment in the below, remembering commit
in the zsh-upstream-bug commit:

https://github.com/zplugin/z-a-test/commit/ddfe30446582f1a7e4b5923858f8fd6836f45d5d

was being ignored IF done before the preceding condition [[ ... ]]
command. When I went back to it to investigate it, it suddenly wasn't
reproducing anymore. But now it again does reproduce itself (!):

https://asciinema.org/a/8DCpuweDsf4j0hcNdpnBfcSjF

I think that possibly the only way to track this is to recall any recent commits
that could have influence this. Or is there maybe a better way? The
problems started when I've switched to Linux, so this could not be
connected to any recent commits.
-- 
Sebastian Gniazdowski
News: https://twitter.com/ZdharmaI
IRC: https://kiwiirc.com/client/chat.freenode.net:+6697/#zplugin
Blog: http://zdharma.org

[-- Attachment #2: commmand.txt --]
[-- Type: text/plain, Size: 10072 bytes --]

typeset -a list=( /junegunn/fzf-bin/releases/download/0.18.0/fzf-0.18.0-darwin_386.tgz /junegunn/fzf-bin/releases/download/0.18.0/fzf-0.18.0-darwin_amd64.tgz /junegunn/fzf-bin/releases/download/0.18.0/fzf-0.18.0-freebsd_386.tgz /junegunn/fzf-bin/releases/download/0.18.0/fzf-0.18.0-freebsd_amd64.tgz /junegunn/fzf-bin/releases/download/0.18.0/fzf-0.18.0-linux_386.tgz /junegunn/fzf-bin/releases/download/0.18.0/fzf-0.18.0-linux_amd64.tgz /junegunn/fzf-bin/releases/download/0.18.0/fzf-0.18.0-linux_arm5.tgz /junegunn/fzf-bin/releases/download/0.18.0/fzf-0.18.0-linux_arm6.tgz /junegunn/fzf-bin/releases/download/0.18.0/fzf-0.18.0-linux_arm7.tgz /junegunn/fzf-bin/releases/download/0.18.0/fzf-0.18.0-linux_arm8.tgz /junegunn/fzf-bin/releases/download/0.18.0/fzf-0.18.0-linux_ppc64le.tgz /junegunn/fzf-bin/releases/download/0.18.0/fzf-0.18.0-openbsd_386.tgz /junegunn/fzf-bin/releases/download/0.18.0/fzf-0.18.0-openbsd_amd64.tgz /junegunn/fzf-bin/releases/download/0.18.0/fzf-0.18.0-windows_386.zip /junegunn/fzf-bin/releases/download/0.18.0/fzf-0.18.0-windows_amd64.zip /junegunn/fzf-bin/releases/download/0.17.5/fzf-0.17.5-darwin_386.tgz /junegunn/fzf-bin/releases/download/0.17.5/fzf-0.17.5-darwin_amd64.tgz /junegunn/fzf-bin/releases/download/0.17.5/fzf-0.17.5-freebsd_386.tgz /junegunn/fzf-bin/releases/download/0.17.5/fzf-0.17.5-freebsd_amd64.tgz /junegunn/fzf-bin/releases/download/0.17.5/fzf-0.17.5-linux_386.tgz /junegunn/fzf-bin/releases/download/0.17.5/fzf-0.17.5-linux_amd64.tgz /junegunn/fzf-bin/releases/download/0.17.5/fzf-0.17.5-linux_arm5.tgz /junegunn/fzf-bin/releases/download/0.17.5/fzf-0.17.5-linux_arm6.tgz /junegunn/fzf-bin/releases/download/0.17.5/fzf-0.17.5-linux_arm7.tgz /junegunn/fzf-bin/releases/download/0.17.5/fzf-0.17.5-linux_arm8.tgz /junegunn/fzf-bin/releases/download/0.17.5/fzf-0.17.5-linux_ppc64le.tgz /junegunn/fzf-bin/releases/download/0.17.5/fzf-0.17.5-openbsd_386.tgz /junegunn/fzf-bin/releases/download/0.17.5/fzf-0.17.5-openbsd_amd64.tgz /junegunn/fzf-bin/releases/download/0.17.5/fzf-0.17.5-windows_386.zip /junegunn/fzf-bin/releases/download/0.17.5/fzf-0.17.5-windows_amd64.zip /junegunn/fzf-bin/releases/download/0.17.4/fzf-0.17.4-darwin_386.tgz /junegunn/fzf-bin/releases/download/0.17.4/fzf-0.17.4-darwin_amd64.tgz /junegunn/fzf-bin/releases/download/0.17.4/fzf-0.17.4-freebsd_386.tgz /junegunn/fzf-bin/releases/download/0.17.4/fzf-0.17.4-freebsd_amd64.tgz /junegunn/fzf-bin/releases/download/0.17.4/fzf-0.17.4-linux_386.tgz /junegunn/fzf-bin/releases/download/0.17.4/fzf-0.17.4-linux_amd64.tgz /junegunn/fzf-bin/releases/download/0.17.4/fzf-0.17.4-linux_arm5.tgz /junegunn/fzf-bin/releases/download/0.17.4/fzf-0.17.4-linux_arm6.tgz /junegunn/fzf-bin/releases/download/0.17.4/fzf-0.17.4-linux_arm7.tgz /junegunn/fzf-bin/releases/download/0.17.4/fzf-0.17.4-linux_arm8.tgz /junegunn/fzf-bin/releases/download/0.17.4/fzf-0.17.4-openbsd_386.tgz /junegunn/fzf-bin/releases/download/0.17.4/fzf-0.17.4-openbsd_amd64.tgz /junegunn/fzf-bin/releases/download/0.17.4/fzf-0.17.4-windows_386.zip /junegunn/fzf-bin/releases/download/0.17.4/fzf-0.17.4-windows_amd64.zip /junegunn/fzf-bin/releases/download/0.17.3/fzf-0.17.3-darwin_386.tgz /junegunn/fzf-bin/releases/download/0.17.3/fzf-0.17.3-darwin_amd64.tgz /junegunn/fzf-bin/releases/download/0.17.3/fzf-0.17.3-freebsd_386.tgz /junegunn/fzf-bin/releases/download/0.17.3/fzf-0.17.3-freebsd_amd64.tgz /junegunn/fzf-bin/releases/download/0.17.3/fzf-0.17.3-linux_386.tgz /junegunn/fzf-bin/releases/download/0.17.3/fzf-0.17.3-linux_amd64.tgz /junegunn/fzf-bin/releases/download/0.17.3/fzf-0.17.3-linux_arm5.tgz /junegunn/fzf-bin/releases/download/0.17.3/fzf-0.17.3-linux_arm6.tgz /junegunn/fzf-bin/releases/download/0.17.3/fzf-0.17.3-linux_arm7.tgz /junegunn/fzf-bin/releases/download/0.17.3/fzf-0.17.3-linux_arm8.tgz /junegunn/fzf-bin/releases/download/0.17.3/fzf-0.17.3-openbsd_386.tgz /junegunn/fzf-bin/releases/download/0.17.3/fzf-0.17.3-openbsd_amd64.tgz /junegunn/fzf-bin/releases/download/0.17.3/fzf-0.17.3-windows_386.zip /junegunn/fzf-bin/releases/download/0.17.3/fzf-0.17.3-windows_amd64.zip /junegunn/fzf-bin/releases/download/0.17.1/fzf-0.17.1-darwin_386.tgz /junegunn/fzf-bin/releases/download/0.17.1/fzf-0.17.1-darwin_amd64.tgz /junegunn/fzf-bin/releases/download/0.17.1/fzf-0.17.1-freebsd_386.tgz /junegunn/fzf-bin/releases/download/0.17.1/fzf-0.17.1-freebsd_amd64.tgz /junegunn/fzf-bin/releases/download/0.17.1/fzf-0.17.1-linux_386.tgz /junegunn/fzf-bin/releases/download/0.17.1/fzf-0.17.1-linux_amd64.tgz /junegunn/fzf-bin/releases/download/0.17.1/fzf-0.17.1-linux_arm5.tgz /junegunn/fzf-bin/releases/download/0.17.1/fzf-0.17.1-linux_arm6.tgz /junegunn/fzf-bin/releases/download/0.17.1/fzf-0.17.1-linux_arm7.tgz /junegunn/fzf-bin/releases/download/0.17.1/fzf-0.17.1-linux_arm8.tgz /junegunn/fzf-bin/releases/download/0.17.1/fzf-0.17.1-openbsd_386.tgz /junegunn/fzf-bin/releases/download/0.17.1/fzf-0.17.1-openbsd_amd64.tgz /junegunn/fzf-bin/releases/download/0.17.1/fzf-0.17.1-windows_386.zip /junegunn/fzf-bin/releases/download/0.17.1/fzf-0.17.1-windows_amd64.zip /junegunn/fzf-bin/releases/download/0.17.0/fzf-0.17.0-darwin_386.tgz /junegunn/fzf-bin/releases/download/0.17.0/fzf-0.17.0-darwin_amd64.tgz /junegunn/fzf-bin/releases/download/0.17.0/fzf-0.17.0-freebsd_386.tgz /junegunn/fzf-bin/releases/download/0.17.0/fzf-0.17.0-freebsd_amd64.tgz /junegunn/fzf-bin/releases/download/0.17.0/fzf-0.17.0-linux_386.tgz /junegunn/fzf-bin/releases/download/0.17.0/fzf-0.17.0-linux_amd64.tgz /junegunn/fzf-bin/releases/download/0.17.0/fzf-0.17.0-linux_arm5.tgz /junegunn/fzf-bin/releases/download/0.17.0/fzf-0.17.0-linux_arm6.tgz /junegunn/fzf-bin/releases/download/0.17.0/fzf-0.17.0-linux_arm7.tgz /junegunn/fzf-bin/releases/download/0.17.0/fzf-0.17.0-linux_arm8.tgz /junegunn/fzf-bin/releases/download/0.17.0/fzf-0.17.0-openbsd_386.tgz /junegunn/fzf-bin/releases/download/0.17.0/fzf-0.17.0-openbsd_amd64.tgz /junegunn/fzf-bin/releases/download/0.17.0/fzf-0.17.0-windows_386.zip /junegunn/fzf-bin/releases/download/0.17.0/fzf-0.17.0-windows_amd64.zip /junegunn/fzf-bin/releases/download/0.16.11/fzf-0.16.11-darwin_386.tgz /junegunn/fzf-bin/releases/download/0.16.11/fzf-0.16.11-darwin_amd64.tgz /junegunn/fzf-bin/releases/download/0.16.11/fzf-0.16.11-freebsd_386.tgz /junegunn/fzf-bin/releases/download/0.16.11/fzf-0.16.11-freebsd_amd64.tgz /junegunn/fzf-bin/releases/download/0.16.11/fzf-0.16.11-linux_386.tgz /junegunn/fzf-bin/releases/download/0.16.11/fzf-0.16.11-linux_amd64.tgz /junegunn/fzf-bin/releases/download/0.16.11/fzf-0.16.11-linux_arm5.tgz /junegunn/fzf-bin/releases/download/0.16.11/fzf-0.16.11-linux_arm6.tgz /junegunn/fzf-bin/releases/download/0.16.11/fzf-0.16.11-linux_arm7.tgz /junegunn/fzf-bin/releases/download/0.16.11/fzf-0.16.11-linux_arm8.tgz /junegunn/fzf-bin/releases/download/0.16.11/fzf-0.16.11-openbsd_386.tgz /junegunn/fzf-bin/releases/download/0.16.11/fzf-0.16.11-openbsd_amd64.tgz /junegunn/fzf-bin/releases/download/0.16.11/fzf-0.16.11-windows_386.zip /junegunn/fzf-bin/releases/download/0.16.11/fzf-0.16.11-windows_amd64.zip /junegunn/fzf-bin/releases/download/0.16.10/fzf-0.16.10-darwin_386.tgz /junegunn/fzf-bin/releases/download/0.16.10/fzf-0.16.10-darwin_amd64.tgz /junegunn/fzf-bin/releases/download/0.16.10/fzf-0.16.10-freebsd_386.tgz /junegunn/fzf-bin/releases/download/0.16.10/fzf-0.16.10-freebsd_amd64.tgz /junegunn/fzf-bin/releases/download/0.16.10/fzf-0.16.10-linux_386.tgz /junegunn/fzf-bin/releases/download/0.16.10/fzf-0.16.10-linux_amd64.tgz /junegunn/fzf-bin/releases/download/0.16.10/fzf-0.16.10-linux_arm5.tgz /junegunn/fzf-bin/releases/download/0.16.10/fzf-0.16.10-linux_arm6.tgz /junegunn/fzf-bin/releases/download/0.16.10/fzf-0.16.10-linux_arm7.tgz /junegunn/fzf-bin/releases/download/0.16.10/fzf-0.16.10-linux_arm8.tgz /junegunn/fzf-bin/releases/download/0.16.10/fzf-0.16.10-openbsd_386.tgz /junegunn/fzf-bin/releases/download/0.16.10/fzf-0.16.10-openbsd_amd64.tgz /junegunn/fzf-bin/releases/download/0.16.10/fzf-0.16.10-windows_386.zip /junegunn/fzf-bin/releases/download/0.16.10/fzf-0.16.10-windows_amd64.zip /junegunn/fzf-bin/releases/download/0.16.9/fzf-0.16.9-darwin_386.tgz /junegunn/fzf-bin/releases/download/0.16.9/fzf-0.16.9-darwin_amd64.tgz /junegunn/fzf-bin/releases/download/0.16.9/fzf-0.16.9-freebsd_386.tgz /junegunn/fzf-bin/releases/download/0.16.9/fzf-0.16.9-freebsd_amd64.tgz /junegunn/fzf-bin/releases/download/0.16.9/fzf-0.16.9-linux_386.tgz /junegunn/fzf-bin/releases/download/0.16.9/fzf-0.16.9-linux_amd64.tgz /junegunn/fzf-bin/releases/download/0.16.9/fzf-0.16.9-linux_arm5.tgz /junegunn/fzf-bin/releases/download/0.16.9/fzf-0.16.9-linux_arm6.tgz /junegunn/fzf-bin/releases/download/0.16.9/fzf-0.16.9-linux_arm7.tgz /junegunn/fzf-bin/releases/download/0.16.9/fzf-0.16.9-linux_arm8.tgz /junegunn/fzf-bin/releases/download/0.16.9/fzf-0.16.9-openbsd_386.tgz /junegunn/fzf-bin/releases/download/0.16.9/fzf-0.16.9-openbsd_amd64.tgz /junegunn/fzf-bin/releases/download/0.16.9/fzf-0.16.9-windows_386.zip /junegunn/fzf-bin/releases/download/0.16.9/fzf-0.16.9-windows_amd64.zip /junegunn/fzf-bin/releases/download/0.16.8/fzf-0.16.8-darwin_386.tgz /junegunn/fzf-bin/releases/download/0.16.8/fzf-0.16.8-darwin_amd64.tgz /junegunn/fzf-bin/releases/download/0.16.8/fzf-0.16.8-freebsd_386.tgz /junegunn/fzf-bin/releases/download/0.16.8/fzf-0.16.8-freebsd_amd64.tgz /junegunn/fzf-bin/releases/download/0.16.8/fzf-0.16.8-linux_386.tgz /junegunn/fzf-bin/releases/download/0.16.8/fzf-0.16.8-linux_amd64.tgz /junegunn/fzf-bin/releases/download/0.16.8/fzf-0.16.8-linux_arm5.tgz /junegunn/fzf-bin/releases/download/0.16.8/fzf-0.16.8-linux_arm6.tgz /junegunn/fzf-bin/releases/download/0.16.8/fzf-0.16.8-linux_arm7.tgz /junegunn/fzf-bin/releases/download/0.16.8/fzf-0.16.8-linux_arm8.tgz /junegunn/fzf-bin/releases/download/0.16.8/fzf-0.16.8-openbsd_386.tgz /junegunn/fzf-bin/releases/download/0.16.8/fzf-0.16.8-openbsd_amd64.tgz /junegunn/fzf-bin/releases/download/0.16.8/fzf-0.16.8-windows_386.zip /junegunn/fzf-bin/releases/download/0.16.8/fzf-0.16.8-windows_amd64.zip )
print -rl ${(M)list[@]:#(#i)*(x86_64|amd64|intel)*}

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: BUG: Random behavior of the shell
  2019-09-29 21:00 BUG: Random behavior of the shell Sebastian Gniazdowski
@ 2019-09-29 22:34 ` Bart Schaefer
  2019-09-30  0:30   ` Sebastian Gniazdowski
  0 siblings, 1 reply; 4+ messages in thread
From: Bart Schaefer @ 2019-09-29 22:34 UTC (permalink / raw)
  To: Sebastian Gniazdowski; +Cc: Zsh hackers list

On Sun, Sep 29, 2019 at 2:03 PM Sebastian Gniazdowski
<sgniazdowski@gmail.com> wrote:
>
> I was getting such behavior earlier, but waited with the report. Now
> it's a more clear one, so I'm reporting: https://youtu.be/N-HH2f_Rr0E

It's really difficult to see what's going on with these recordings you
keep posting.  Video compression often makes them go by even faster
than real-time, and when the list of results you're displaying more
than fills the screen it's a pain to step backwards to see what you
were doing before.  If you must resort to visual aids, a series of
still screen shots would be better.  That said ...

> The list isn't getting filtered.
>
> Earlier was: the `quiet=1` assignment in the below

These don't seem very likely to be closely related problems.  This
most recent one looks like a pattern matching issue, the other looks
like perhaps an exit status is leaking from one conditional test to
another.  Why do you have a [[ ... ]] standing all by itself as a
command, with nothing testing the results?  (Not that this should
cause a bug.)

> problems started when I've switched to Linux, so this could not be
> connected to any recent commits.

This isn't by any chance the same version of linux where Dennis is
reporting problems with trap functions?

I saw a "long long" vs. "long" error go by in compiler output in one
of those videos.  Could wordcode be getting messed up by a default
integer byte-width in some circumstances, or something like that?

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: BUG: Random behavior of the shell
  2019-09-29 22:34 ` Bart Schaefer
@ 2019-09-30  0:30   ` Sebastian Gniazdowski
  2019-09-30  0:32     ` Sebastian Gniazdowski
  0 siblings, 1 reply; 4+ messages in thread
From: Sebastian Gniazdowski @ 2019-09-30  0:30 UTC (permalink / raw)
  To: Bart Schaefer; +Cc: Zsh hackers list

On Mon, 30 Sep 2019 at 00:34, Bart Schaefer <schaefer@brasslantern.com> wrote:
>
> On Sun, Sep 29, 2019 at 2:03 PM Sebastian Gniazdowski
> <sgniazdowski@gmail.com> wrote:
> >
> > I was getting such behavior earlier, but waited with the report. Now
> > it's a more clear one, so I'm reporting: https://youtu.be/N-HH2f_Rr0E
>
> It's really difficult to see what's going on with these recordings you
> keep posting.  Video compression often makes them go by even faster
> than real-time, and when the list of results you're displaying more
> than fills the screen it's a pain to step backwards to see what you
> were doing before.  If you must resort to visual aids, a series of
> still screen shots would be better.  That said ...

Ok, I'll remember the tip about the screen shots. The video is a proof
that I'm not making things up, that the shell really does behave in an
unpredictable manner. It also allows to go back and see what was
happening after a time, like when you point later about the long vs.
long long warnings from GCC.

> > The list isn't getting filtered.
> >
> > Earlier was: the `quiet=1` assignment in the below
>
> These don't seem very likely to be closely related problems.  This
> most recent one looks like a pattern matching issue, the other looks
> like perhaps an exit status is leaking from one conditional test to
> another.  Why do you have a [[ ... ]] standing all by itself as a
> command, with nothing testing the results?  (Not that this should
> cause a bug.)

I've minimized the test case, that's why I've removed a print -P from
the conditional command.

I think that the issues are related like when you state later – by a
general problem. It's not the only random behavior that I've observed
– earlier my plugin zconvey just wasn't working, to then start working
without problems. I've now switched to own zsh build and the problems
disappear, so it might be some problem with Mageia's build of Zsh.

> > problems started when I've switched to Linux, so this could not be
> > connected to any recent commits.
>
> This isn't by any chance the same version of linux where Dennis is
> reporting problems with trap functions?

I think not, mine is Mageia 7.

> I saw a "long long" vs. "long" error go by in compiler output in one
> of those videos.  Could wordcode be getting messed up by a default
> integer byte-width in some circumstances, or something like that?

It seems that the warning is related to printf() format string.
However I'm starting to think that this is a problem with a subtle
build error in the Mageia's Zsh distribution. However, shouldn't such
error reveal itself much more often?

-- 
Sebastian Gniazdowski
News: https://twitter.com/ZdharmaI
IRC: https://kiwiirc.com/client/chat.freenode.net:+6697/#zplugin
Blog: http://zdharma.org

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: BUG: Random behavior of the shell
  2019-09-30  0:30   ` Sebastian Gniazdowski
@ 2019-09-30  0:32     ` Sebastian Gniazdowski
  0 siblings, 0 replies; 4+ messages in thread
From: Sebastian Gniazdowski @ 2019-09-30  0:32 UTC (permalink / raw)
  To: Bart Schaefer; +Cc: Zsh hackers list

On Mon, 30 Sep 2019 at 02:30, Sebastian Gniazdowski
<sgniazdowski@gmail.com> wrote:
> I've minimized the test case, that's why I've removed a print -P from
> the conditional command.

Also, recalling the previous errreturn resolution, I've added "||
true" after the conditional, and the problem remained.

-- 
Sebastian Gniazdowski
News: https://twitter.com/ZdharmaI
IRC: https://kiwiirc.com/client/chat.freenode.net:+6697/#zplugin
Blog: http://zdharma.org

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2019-09-30  0:36 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-09-29 21:00 BUG: Random behavior of the shell Sebastian Gniazdowski
2019-09-29 22:34 ` Bart Schaefer
2019-09-30  0:30   ` Sebastian Gniazdowski
2019-09-30  0:32     ` Sebastian Gniazdowski

Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).