Subject: Re: bug#68808: subsecond mtime discovery code insufficient

From: Erik A Johnson <[email-masked]>
Date: Thu, 30 May 2024 23:38:31 +0000

Hi, Karl.  As you suspected, this was an issue of making in parallel.  This was with the old make 3.81: my MAKEFLAGS is set to "-k -j12"; unsetting MAKEFLAGS and running works fine, with all tests passing.

Do color-tests2.sh and color-tests2-w.sh both write to the same directory and, thus, running in parallel may have caused them to be writing to the same file(s) at the same time?

With -j12 and the old make, it doesn't fail every time, just sometimes, so it's probably the luck of which tests are running in parallel when.

Should the color test be changed to not re-use the same directory or filenames? or that one test must come before the other?

Erik

P.S. For the original failing parallel make 3.81, the final stdout contents were:

	spawn make -e check
	make  pass fail skip xpass xfail error
	make[1]: Nothing to be done for `pass'.
	make[1]: Nothing to be done for `fail'.
	make[1]: Nothing to be done for `skip'.
	make[1]: Nothing to be done for `xpass'.
	make[1]: Nothing to be done for `xfail'.
	make[1]: Nothing to be done for `error'.
	make  check-TESTS
	^[[0;32mPASS^[[m: pass

> On May 29, 2024, at 2:53 PM, Karl Berry <[email-masked]> wrote:
> 
> Hi Erik,
> 
>    * color-tests2.sh and color-tests2-w.sh fail -- logs attached.
> 
> Is this with the old make 3.81 from the system, or the new make you
> compiled? What is in the "stdout" file in t/color-tests2.dir/stdout?
> And, are these the only two tests that fail in the entire suite?
> 
> What I see in the log you sent is that color-tests2.log correctly runs 
>  make  pass fail skip xpass xfail error
> But then the test output only shows the PASS line:
> ..
> make  check-TESTS
> ^[[0;32mPASS^[[m: pass
> + test_color
> ..
> I believe that is doing "cat stdout", so everything else is missing,
> even the Automake "Testsuite summary" footer.
> 
> I don't know why. It's as if the output from the parallel running of
> make check overwrote itself, or maybe never ran. But this is not a
> problem that's ever been reported before (and doesn't happen for me),
> and I haven't knowingly changed anything here.
> 
> Thus I somewhat suspect this is some problem of make, and/or expect,
> and/or something else. If it's something we can detect, we could skip
> the test if we can't fix it. Help?
> 
> On my system, I see (I'll attach the whole log):
> ..
> make  check-TESTS
> make[1]: Entering directory '/u/karl/gnu/src/akarl/t/color-tests2.dir'
> make[2]: Entering directory '/u/karl/gnu/src/akarl/t/color-tests2.dir'
> ^[[0;32mPASS^[[m: pass
> ^[[0;31mFAIL^[[m: fail
> ^[[1;34mSKIP^[[m: skip
> ^[[0;31mXPASS^[[m: xpass
> ^[[1;32mXFAIL^[[m: xfail
> ^[[0;35mERROR^[[m: error
> ^[[0;31m============================================================================^[[m
> ^[[0;31mTestsuite summary for color-tests2 1.0^[[m
> ..
> + test_color
> ..
> 
> (For the sake of this mail, I've removed ^M characters and replaced true
> ^[ ESC character with ASCII ^[.)
> 
> BTW, color-tests2-w is just a wrapper of color-tests2 to test VPATH, so
> if we can solve color-tests2, its problems should go away too.
> 
> Thanks,
> Karl
> 
> <color-tests2.log>