ruby-core@ruby-lang.org archive (unofficial mirror)
 help / color / mirror / Atom feed
From: jaruga@redhat.com
To: ruby-core@ruby-lang.org
Subject: [ruby-core:103950] [Ruby master Bug#17878] test_ractor.rb: a random failing test with "The outgoing-port is already closed (Ractor::ClosedError)"
Date: Fri, 21 May 2021 14:25:42 +0000 (UTC)	[thread overview]
Message-ID: <redmine.issue-17878.20210521142541.11018@ruby-lang.org> (raw)
In-Reply-To: redmine.issue-17878.20210521142541.11018@ruby-lang.org

Issue #17878 has been reported by jaruga (Jun Aruga).

----------------------------------------
Bug #17878: test_ractor.rb: a random failing test with "The outgoing-port is already closed (Ractor::ClosedError)"
https://bugs.ruby-lang.org/issues/17878

* Author: jaruga (Jun Aruga)
* Status: Open
* Priority: Normal
* Backport: 2.6: UNKNOWN, 2.7: UNKNOWN, 3.0: UNKNOWN
----------------------------------------
I was running Travis several times I am trying to revive based on the master commit: `50a534a1526e2b9f4ea41e44b802bd73f9cebbeb`.
Then I got the following failure on Travis arm64 Ubuntu focal environment. The failure happened for the first time in around 5 times.

Here is the Travis log.
https://travis-ci.com/github/junaruga/ruby/jobs/506885939#L2227

```
$ $SETARCH make -s test -o showflags TESTOPTS="${TESTOPTS=-j33 -q --tty=no}"
...
test_ractor.rb           ....................Fstderr output is not empty
   <internal:ractor>:345:in `select': The outgoing-port is already closed (Ractor::ClosedError)
           from bootstraptest.tmp.rb:12:in `block in test'
           from bootstraptest.tmp.rb:11:in `times'
           from bootstraptest.tmp.rb:11:in `test'
           from bootstraptest.tmp.rb:26:in `block in <main>'
           from bootstraptest.tmp.rb:25:in `times'
           from bootstraptest.tmp.rb:25:in `each'
           from bootstraptest.tmp.rb:25:in `map'
           from bootstraptest.tmp.rb:25:in `<main>'
```

```
Fiber count: 10000 (skipping)
#1213 test_ractor.rb:224:in `<top (required)>': 
     def test n
       rs = (1..n).map do |i|
         Ractor.new(i) do |i|
           "r#{i}"
         end
       end
       as = []
       all_rs = rs.dup

       n.times{
         r, obj = Ractor.select(*rs)
         as << [r, obj]
         rs.delete(r)
       }

       if as.map{|r, o| r.object_id}.sort == all_rs.map{|r| r.object_id}.sort &&
          as.map{|r, o| o}.sort == (1..n).map{|i| "r#{i}"}.sort
         'ok'
       else
         'ng'
       end
     end
   
     30.times.map{|i|
       test i
     }
  #=> "" (expected "[\"ok\", \"ok\", \"ok\", \"ok\", \"ok\", \"ok\", \"ok\", \"ok\", \"ok\", \"ok\", \"ok\", \"ok\", \"ok\", \"ok\", \"ok\", \"ok\", \"ok\", \"ok\", \"ok\", \"ok\", \"ok\", \"ok\", \"ok\", \"ok\", \"ok\", \"ok\", \"ok\", \"ok\", \"ok\", \"ok\"]")  
FAIL 1/1488 tests failed
make: *** [uncommon.mk:768: yes-btest-ruby] Error 1
The command "$SETARCH make -s test -o showflags TESTOPTS="${TESTOPTS=$JOBS -q --tty=no}"" exited with 2.
```




-- 
https://bugs.ruby-lang.org/

       reply	other threads:[~2021-05-21 14:25 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-05-21 14:25 jaruga [this message]
2021-05-22 11:37 ` [ruby-core:103973] [Ruby master Bug#17878] test_ractor.rb: a random failing test with "The outgoing-port is already closed (Ractor::ClosedError)" jaruga
2021-05-29 20:17 ` [ruby-core:104099] [Ruby master Bug#17878] bootstraptest/test_ractor.rb:224 " xtkoba+ruby
2021-09-13 13:10 ` [ruby-core:105219] " xtkoba (Tee KOBAYASHI)
2024-04-03  4:26 ` [ruby-core:117416] " hsbt (Hiroshi SHIBATA) via ruby-core

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-list from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.ruby-lang.org/en/community/mailing-lists/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=redmine.issue-17878.20210521142541.11018@ruby-lang.org \
    --to=ruby-core@ruby-lang.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).