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
IO.slurp throws exception when run in threads #6638
Comments
From @lefthThe exception is: I've observed this error on both Linux and Windows 10, on the September and while perl6 ./concurrency-test.p6 $DIR; do :; done This problem only occurs with slurp. When I instead open a file handle, The test case I used to show this issue is uploaded here: |
From @zoffixznetHi, Having trouble reproducing this on Linux on 2017.10-177-g77048b6 in a dir with 33k files that have one line of text each. - Can you inlcude the exact version (perl6 -v) to go with the --ll-exception stack trace so we can examine the referenced core code? I tried following the line numbers in the trace you gave with 2017.09 and 2017.10 releases, but they don't seem to quite match up
Does it happen if you use the handle's .slurp method? i.e. open($file-path).slurp: :close; Let us know. Thanks. |
The RT System itself - Status changed from 'new' to 'open' |
From @lefthIt seems this has already been resolved on the master branch. After making On Wed, Nov 15, 2017 at 2:59 AM perl6 via RT <perl6-bugs-followup@perl.org>
|
From @AlexDanielMarked as 「 testneeded」 to make sure we have tests for it. If there are tests already, then it should be linked and the ticket can be closed. On 2017-11-15 14:43:51, dan@zwell.net wrote:
|
From @lefthAfter more careful checking, I found the bug fix did make it into the Got exception: Cannot assign to an immutable value in method slurp at Died I found I can reproduce the error within 1-4 iterations when running the Slurping on the file handle you described still produces the On Thu, Nov 16, 2017 at 7:58 AM Aleks-Daniel Jakimenko-Aleksejev via RT <
|
From @zoffixznetOn Fri, 17 Nov 2017 09:26:10 -0800, dan@zwell.net wrote:
Great. The behaviour you describe matches the commit; without :close the buggy path is not taken.
I tried writing the test to cover this bug, but out of dozens of things I tried (including trying your original script on rakudo's dir), I just can't reproduce the failure. Does this crash on your computer when using commits before the fix, by any chance? given |
From @lefthOh, and when the list of filenames is the simpler `"$*TMPDIR/RT132447.test" On Sat, Nov 18, 2017 at 4:01 PM Dan Zwell <dan@zwell.net> wrote:
|
From @lefthThanks for taking the time to look into this! I can't reproduce it with perl6 -e '"$*TMPDIR/RT132447.test".IO.spurt: "a" x 400_000;' On Sat, Nov 18, 2017 at 3:28 AM Zoffix Znet via RT <
|
Migrated from rt.perl.org#132447 (status was 'open')
Searchable as RT132447$
The text was updated successfully, but these errors were encountered: