-
Notifications
You must be signed in to change notification settings - Fork 359
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[2.3.0~beta1 regression] Long columns are misaligned #6243
Comments
I was able to bisect quickly and found the origin in #6230. Apparently |
Something feels fishy in the standard library: # let ic, _ = Unix.open_process_args "/usr/bin/tput" [|"/usr/bin/tput"; "cols"|];;
val ic : in_channel = <abstr>
# input_line ic;;
- : string = "107"
# let ic, _, _ = Unix.open_process_args_full "/usr/bin/tput" [|"/usr/bin/tput"; "cols"|] (Unix.environment ());;
val ic : in_channel = <abstr>
# input_line ic;;
- : string = "80" |
ok, i got to the bottom of this. It looks like you can't get the proper result from $ tput cols
215
$ tput cols > /tmp/stdout << EOF
EOF
$ cat /tmp/stdout
215
$ tput cols > /tmp/stdout 2> /tmp/stderr
$ cat /tmp/stdout
215
$ tput cols > /tmp/stdout 2> /tmp/stderr << EOF
EOF
$ cat /tmp/stdout
80 I'll try to think at a fix tomorrow |
I guess the idea is that you need one that isatty no ? |
Btw. I was curious on how I solved that problem in |
My first thought on how to fix this so far is to bind |
Looks cleaner. I'm not sure why I didn't do that in |
Funnily enoughmaster
(built with glibc) exhibits the same behaviour as2.3.0~alpha1
so my guess is that this somehow comes from #6237, most likely the upgrade to Alpine 3.20. Maybe a bug in musl?EDIT: Nevermind i built the wrong branch, i'm able to reproduce with master with glibc also so it's not a musl issue.
The text was updated successfully, but these errors were encountered: