Project

General

Profile

Actions

Bug #18759

closed

snapshot-ruby_2_7: test failure on macos-12

Added by znz (Kazuhiro NISHIYAMA) over 2 years ago. Updated about 2 years ago.

Status:
Closed
Assignee:
-
Target version:
-
[ruby-dev:51181]

Description

snapshot tarball のテストに macos-12 を追加したところ、 snapshot-ruby_2_7 で failure が発生していました。

https://github.com/ruby/actions/runs/6199339063?check_suite_focus=true#step:17:138


  1) Failure:
TestRipper::ParserEvents#test_block_variables [/Users/runner/work/actions/actions/snapshot-ruby_2_7/test/ripper/test_parser_events.rb:1506]:
[ruby-dev:39423]
pid 44233 exit 1
| -:1:in `setrlimit': Invalid argument - setrlimit (Errno::EINVAL)
| 	from -:1:in `<main>'
.

1. [1/2] Assertion for "stdout"
   | <["[fcall(proc,[],&block([],[unary(!,ref(y))]))]"]> expected but was
   | <[]>.

2. [2/2] Assertion for "stderr"
   | <[]> expected but was
   | <["-:1:in `setrlimit': Invalid argument - setrlimit (Errno::EINVAL)",
   |  "\tfrom -:1:in `<main>'"]>.

該当するテストは master では https://github.com/ruby/ruby/commit/1c7f5a57125001447dc6173847dc68aa50bd8e93 で setrlimit を使わないようになっていました。

コマンドラインでいくつかの値を試してみたところ、 macos-12 での EINVAL は設定しようとしている値が小さすぎるからのようでした。

% /usr/bin/ruby -ve 'Process.setrlimit(Process::RLIMIT_AS, 1000*1024*1024)'
ruby 2.6.8p205 (2021-07-07 revision 67951) [universal.arm64e-darwin21]
-e:1:in `setrlimit': Invalid argument - setrlimit (Errno::EINVAL)
	from -e:1:in `<main>'
 % /usr/bin/ruby -ve 'lim=Process.getrlimit(Process::RLIMIT_AS); p lim; Process.setrlimit(Process::RLIMIT_AS, lim[0]/2); p Process.getrlimit(Process::RLIMIT_AS)' 
ruby 2.6.8p205 (2021-07-07 revision 67951) [universal.arm64e-darwin21]
[9223372036854775807, 9223372036854775807]
[4611686018427387903, 4611686018427387903]
Actions #1

Updated by znz (Kazuhiro NISHIYAMA) about 2 years ago

  • Status changed from Open to Closed
Actions #2

Updated by usa (Usaku NAKAMURA) about 2 years ago

  • Backport changed from 2.7: UNKNOWN, 3.0: UNKNOWN, 3.1: UNKNOWN to 2.7: REQUIRED, 3.0: UNKNOWN, 3.1: UNKNOWN
Actions

Also available in: Atom PDF

Like0
Like0Like0