Latest cogito broken with bash-3.1
Hi Petr,
I have a Ubuntu Dapper running and since their update to the latest bash version the cg-commit command (and maybe others) is broken. It reports:
GNU bash, version 3.1.0(1)-release (x86_64-pc-linux-gnu) Copyright (C) 2005 Free Software Foundation, Inc.
The cogito is the latest from kernel.org and when calling cg-commit it fails with this message:
cg-commit: line 200: syntax error near unexpected token `('
cg-commit: line 200: ` eval commitfiles=($(cat $filter | path_xargs git-diff-index -r -m HEAD -- | \'
I played a little bit with it and it seems all the eval statements are broken with this bash version. I have no clue how to fix this, but maybe you do.
Regards
Marcel
Hello,
Dear diary, on Sat, Dec 10, 2005 at 02:18:44PM CET, I got a letter where Marcel Holtmann <[email protected]> said that...
Quoted 9 lines
The cogito is the latest from kernel.org and when calling cg-commit it fails with this message:
cg-commit: line 200: syntax error near unexpected token `('
cg-commit: line 200: ` eval commitfiles=($(cat $filter |path_xargsgit-diff-index -r -m HEAD -- | \'I played a little bit with it and it seems all the eval statements are broken with this bash version. I have no clue how to fix this, but maybe you do.
it seems like the newer bash is stricter than the older versions in
some obscure regards. Quoting the eval arguments (which is the proper thing to do anyway) fixed that particular problem; I've hit another problem during a test commit wrt. whitespace separators - I've fixed that too, and pushed out.
Thanks,
Signature · 4 lines
Petr "Pasky" Baudis Stuff: http://pasky.or.cz/ VI has two modes: the one in which it beeps and the one in which it doesn't.
Hi Petr,
Quoted 10 lines
Quoted 9 lines
The cogito is the latest from kernel.org and when calling cg-commit it fails with this message:
cg-commit: line 200: syntax error near unexpected token `('
cg-commit: line 200: ` eval commitfiles=($(cat $filter |path_xargsgit-diff-index -r -m HEAD -- | \'I played a little bit with it and it seems all the eval statements are broken with this bash version. I have no clue how to fix this, but maybe you do.
Quoted 5 lines
it seems like the newer bash is stricter than the older versions in
some obscure regards. Quoting the eval arguments (which is the proper thing to do anyway) fixed that particular problem; I've hit another problem during a test commit wrt. whitespace separators - I've fixed that too, and pushed out.
it's now working again. Thanks. What do you think about another release? I haven't checked the other distributions yet, but I just saw that Debian unstable also moved to version 3.1 of bash.
There exists also another problem with the new bash. It is the broken pipe error from cg-log.
cg-log: line 141: echo: write error: Broken pipe
The line number varies depending how much you scrolled and when you scrolled to the end no broken pipe error comes up. Do you have any idea on how to deal with this. I saw your comment about that bash is broken and the extra trap command, but it doesn't help. I never saw that problem with older versions of bash.
Regards
Marcel
Hello,
Dear diary, on Sun, Dec 11, 2005 at 09:31:07AM CET, I got a letter where Marcel Holtmann <[email protected]> said that...
Quoted 3 lines
it's now working again. Thanks. What do you think about another release? I haven't checked the other distributions yet, but I just saw that Debian unstable also moved to version 3.1 of bash.
yes, I was planning 0.16.1 on Sunday anyway. Going to tag it now.
Quoted 10 lines
There exists also another problem with the new bash. It is the broken pipe error from cg-log.
cg-log: line 141: echo: write error: Broken pipe
The line number varies depending how much you scrolled and when you scrolled to the end no broken pipe error comes up. Do you have any idea on how to deal with this. I saw your comment about that bash is broken and the extra trap command, but it doesn't help. I never saw that problem with older versions of bash.
Then that's quite funny, one-line broken pipe message has been always
there (in the past it looked much worse, we thankfully managed to bring it down to this at least).
Signature · 4 lines
Petr "Pasky" Baudis Stuff: http://pasky.or.cz/ VI has two modes: the one in which it beeps and the one in which it doesn't.
Hi Petr,
Quoted 11 lines
Quoted 10 lines
There exists also another problem with the new bash. It is the broken pipe error from cg-log.
cg-log: line 141: echo: write error: Broken pipe
The line number varies depending how much you scrolled and when you scrolled to the end no broken pipe error comes up. Do you have any idea on how to deal with this. I saw your comment about that bash is broken and the extra trap command, but it doesn't help. I never saw that problem with older versions of bash.
Quoted 3 lines
Then that's quite funny, one-line broken pipe message has been always
there (in the past it looked much worse, we thankfully managed to bring it down to this at least).
I have some machines where I stopped installing the latest bash version and they don't have this problem. With bash-2.05b.0 and bash-3.00.16 I never (and really mean never) saw this problem.
It is not related to this, but the make-3.81beta3 breaks all my Debian package rules and I don't have the slightest idea why. It seems that they try to fix some Posix issues and make it worse then any better :(
Regards
Marcel
Hi,
Dear diary, on Mon, Dec 12, 2005 at 10:30:01AM CET, I got a letter where Marcel Holtmann <[email protected]> said that...
Quoted 11 lines
Quoted 11 lines
Quoted 10 lines
There exists also another problem with the new bash. It is the broken pipe error from cg-log.
cg-log: line 141: echo: write error: Broken pipe
The line number varies depending how much you scrolled and when you scrolled to the end no broken pipe error comes up. Do you have any idea on how to deal with this. I saw your comment about that bash is broken and the extra trap command, but it doesn't help. I never saw that problem with older versions of bash.
Quoted 7 lines
Quoted 3 lines
Then that's quite funny, one-line broken pipe message has been always
there (in the past it looked much worse, we thankfully managed to bring it down to this at least).I have some machines where I stopped installing the latest bash version and they don't have this problem. With bash-2.05b.0 and bash-3.00.16 I never (and really mean never) saw this problem.
this might be some Debian patches then. Indeed, with bash-3.00.16 on
both systems, the line is shown on my home Gentoo system but not on my Debian machine at work. On RHEL at kernel.org the line is not printed either. Hmm. So either it's not really bash what emits this (but what then?) or most of the distributions override that stupid bash behaviour with a patch already. And Debian didn't foreport the patch to bash-3.1. Well, this would make the weekend research more interesting, at least. ;-)
Signature · 4 lines
Petr "Pasky" Baudis Stuff: http://pasky.or.cz/ VI has two modes: the one in which it beeps and the one in which it doesn't.
Hi Petr,
Quoted 19 lines
Quoted 11 lines
Quoted 11 lines
Quoted 10 lines
There exists also another problem with the new bash. It is the broken pipe error from cg-log.
cg-log: line 141: echo: write error: Broken pipe
The line number varies depending how much you scrolled and when you scrolled to the end no broken pipe error comes up. Do you have any idea on how to deal with this. I saw your comment about that bash is broken and the extra trap command, but it doesn't help. I never saw that problem with older versions of bash.
Quoted 7 lines
Quoted 3 lines
Then that's quite funny, one-line broken pipe message has been always
there (in the past it looked much worse, we thankfully managed to bring it down to this at least).I have some machines where I stopped installing the latest bash version and they don't have this problem. With bash-2.05b.0 and bash-3.00.16 I never (and really mean never) saw this problem.
Quoted 6 lines
this might be some Debian patches then. Indeed, with bash-3.00.16 on
both systems, the line is shown on my home Gentoo system but not on my Debian machine at work. On RHEL at kernel.org the line is not printed either. Hmm. So either it's not really bash what emits this (but what then?) or most of the distributions override that stupid bash behaviour with a patch already. And Debian didn't foreport the patch to bash-3.1.
I just verified that on my Ubuntu Dapper system where I had a copy of the old bash package lying around. The bash-3.0 works fine, but the bash-3.1 produces this error. So it is definitely bash related.
Regards
Marcel
Quoted 4 lines · Marcel Holtmann
I just verified that on my Ubuntu Dapper system where I had a copy of the old bash package lying around. The bash-3.0 works fine, but the bash-3.1 produces this error. So it is definitely bash related.
It's been around forever, and it's a bash default installation issue. It's just that all sane distributions will change the default.
Sounds like debian forgot to do that when upgrading to bash-3.1.
The magic incantation is hidden in the bash FAQ (E2):
You can build a version of bash that will not report SIGPIPE errors by uncommenting the definition of DONT_REPORT_SIGPIPE in the file config-top.h.
and I still don't understand why it's not the default. Oh, well.
Linus
Quoted 3 lines · Petr Baudis
Then that's quite funny, one-line broken pipe message has been always
there (in the past it looked much worse, we thankfully managed to bring it down to this at least).
I assume there's no reasonable workaround to that then? What would take to get rid of that (say, if I had a boring weekend ;)?
cheers,
m
Dear diary, on Mon, Dec 12, 2005 at 01:58:00AM CET, I got a letter where Martin Langhoff <[email protected]> said that...
Quoted 6 lines · Petr Baudis
Quoted 3 lines
Then that's quite funny, one-line broken pipe message has been always
there (in the past it looked much worse, we thankfully managed to bring it down to this at least).I assume there's no reasonable workaround to that then?
The trapping is apparently the best we can do - at least I know of nothing better.
Quoted 1 line
What would take to get rid of that (say, if I had a boring weekend ;)?
Fixing bash, IIRC - and more importantly, convincing its maintainers to take the patch. ;-) Sometime in the spring someone even posted the exact location in bash where this is broken.
Signature · 4 lines
Petr "Pasky" Baudis Stuff: http://pasky.or.cz/ VI has two modes: the one in which it beeps and the one in which it doesn't.