git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Funny test flake failure: t7518-ident-corner-cases.sh, test 1

From
Elijah Newren <newren@gmail.com>
Date
Oct 16, 2020, 19:29 UTC
Message-ID
<CABPp-BHQK-AtAJa6V1mtu6_jq3oeUeL_0p00RCRNA6Jw3DpJSg@mail.gmail.com>
Hi,

On my update to my test-selection series, where I simply added more text to t/README, I saw a failure in the GitHub Actions testing despite the same series having previously passed without that extra text. The extra text was unrelated; the failure is due to unsafe environment assumptions (though ones I probably would have made too...). See the actual output here:

https://github.com/git/git/pull/878/checks?check_run_id=1266009463
The issue comes from this test code:
       (
               sane_unset GIT_AUTHOR_EMAIL &&
               GIT_AUTHOR_NAME= &&
               test_must_fail git commit --allow-empty -m foo 2>err &&
               test_i18ngrep ! null err
       )

The last line expects 'null' to NOT be found in err, unfortunately, the file err contained the line:

fatal: empty ident name (for <runner@fv-az128-670.gcliasfzo2nullsdbrimjtbyhg.cx.internal.cloudapp.net>) not allowed 218

Note that 'null' appears as a substring of the domain name, found within 'gcliasfzo2nullsdbrimjtbyhg'.

This testcase was introduced in commit 862e80a413 ("ident: handle NULL email when complaining of empty name", 2017-02-23), and the reason for the check appears in a comment above the test:

+# confirm that we do not segfault _and_ that we do not say "(null)", as +# glibc systems will quietly handle our NULL pointer

Should we tighten the test to check for "(null)" instead of "null", or should we do something else? Or just ignore it as it is somewhat unlikely that anyone ever hits this flake again?

Next: Jeff King
Message 1 of 2 in “Funny test flake failure: t7518-ident-corner-cases.sh, test 1”
  1. Elijah NewrenOct 16, 2020
  2. Jeff KingOct 16, 2020

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.