Skip to content
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

v3.10.0 doesn't have the full fix for reading in while loops hanging #1119

Open
andrewimeson opened this issue Jan 10, 2025 · 1 comment
Open

Comments

@andrewimeson
Copy link

andrewimeson commented Jan 10, 2025

Continuation of #1099. For some reason, despite the fix and new tests added in f3c9101 passing, the issue wasn't fixed until aecfbc3. Could we get a release soon that has that commit? Thanks for all your work on this tool!

This is the script that still hangs on all of these in v3.10.0. It might be good to figure out why the tests didn't actually surface the failure.

#!/usr/bin/env gosh
set -x

echo a > f; while read a; do echo $a; done < f

echo "hi pipe" | while read -r line; do
    echo "$line"
done

while read a; do echo $a; done < <(echo x)

exit 0

echo "hi file" > hi.txt

while read -r line; do
    echo "$line"
done < hi.txt


while read -r line; do
    echo "$line"
done < <(echo "hi file substitution")

echo done
@mvdan
Copy link
Owner

mvdan commented Jan 12, 2025

I'm not particularly surprised that aecfbc3 fixed more edge cases, as it removed a significant amount of complexity coming from a third party library whose behavior I don't fully understand.

Is there a reason why go-task can't use our library at master until we are ready for a release? I will do a release soon, probably in the next few weeks, but I'd rather not be rushed into a release right now. The commit above is also a bit too risky for a backport.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants