ruby / ruby/rdoc

Unstable TestRDocGeneratorJsonIndex#test_generate test

Open
#1,048 5 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Ruby
Stars
930
Forks
465
Avg merge
3d 10h
Merged PRs (30d)
27

Description

I am seeing the following failure that happens randomly on Travis Ubuntu jammy ppc64le environment in ruby/ruby. The latest failure is at the relatively recent commit https://github.com/ruby/ruby/commit/1d51e4cadfbc1f445d00887189e06047759c9aec .

https://app.travis-ci.com/github/ruby/ruby/jobs/612435804#L2936

  1) Failure:
TestRDocGeneratorJsonIndex#test_generate [/home/travis/build/ruby/ruby/test/rdoc/test_rdoc_generator_json_index.rb:108]:
.js files should be the same timestamp of original

The test is built and executed with the following steps.

+ export NPROC="$(nproc)"
+ export JOBS=-j$((1+${NPROC}))
+ export RUBY_TESTOPTS="$JOBS -q --tty=no"
+ export optflags=-O1
+ export debugflags=-ggdb3
+ export CC=gcc-11
+ gcc-11 --version
gcc-11 (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0
Copyright (C) 2021 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
$ ../tool/travis_wait.sh $SETARCH make -s test-all RUBYOPT="-w"
...
Run options: 
  --seed=2200
  "--ruby=./miniruby -I../lib -I. -I.ext/common  ../tool/runruby.rb --extout=.ext  -- --disable-gems"
  --excludes-dir=../test/.excludes
  --name=!/memory_leak/
  -j3
  -q
  --tty=no

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with test/rdoc/test_rdoc_generator_json_index.rb at line 108 and inspect the timestamp assertion in TestRDocGeneratorJsonIndex#test_generate. Reproduce under the reported Travis Ubuntu jammy ppc64le settings with make test-all and the shown RUBY_TESTOPTS, then determine why the generated .js timestamp differs intermittently. Done means the test reliably passes while still checking the expected timestamp.

Written by the indexing model from the issue text.

Assessment

Tech stack
ruby
Domain
testing
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.