Marked 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, d...@zwell.net wrote: > It seems this has already been resolved on the master branch. After > making > a new build, I cannot reproduce the problem. Can you close the bug > report? > Thanks! > > On Wed, Nov 15, 2017 at 2:59 AM perl6 via RT <perl6-bugs- > follo...@perl.org> > wrote: > > > Greetings, > > > > This message has been automatically generated in response to the > > creation of a trouble ticket regarding: > > "IO.slurp throws exception when run in threads", > > a summary of which appears below. > > > > There is no need to reply to this message right now. Your ticket has > > been > > assigned an ID of [perl #132447]. > > > > Please include the string: > > > > [perl #132447] > > > > in the subject line of all future correspondence about this issue. To > > do > > so, > > you may reply to this message. > > > > Thank you, > > perl6-bugs-follo...@perl.org > > > > ------------------------------------------------------------------------- > > The exception is: > > Cannot assign to an immutable value in method slurp at > > SETTING::src/core/IO/Handle.pm line 698 > > in method slurp at SETTING::src/core/IO/Path.pm line 603 > > in block at ./concurrency-test.p6 line 40 > > in block at SETTING::src/core/Promise.pm line 217 > > in block at SETTING::src/core/ThreadPoolScheduler.pm line 284 > > in block at SETTING::src/core/ThreadPoolScheduler.pm line 173 > > in block at SETTING::src/core/ThreadPoolScheduler.pm line 166 > > in block at SETTING::src/core/ThreadPoolScheduler.pm line 163 > > > > I've observed this error on both Linux and Windows 10, on the > > September and > > October Rakudo releases. It's intermittent, so I use a shell loop to > > run my > > test case repeatedly until the problem occurs: > > > > while perl6 ./concurrency-test.p6 $DIR; do :; done > > (where $DIR is any directory that contains several thousand files.) > > > > This problem only occurs with slurp. When I instead open a file > > handle, > > read its full contents with `.lines.cache`, then close the handle, > > there is > > no exception. > > > > The test case I used to show this issue is uploaded here: > > https://gist.github.com/lefth/6d71ca714ca2dc184220a91ceb41334d > > > >