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

Re: pre-v2.34.0-rc0 regressions: t7900-maintenance.sh broken due to 'systemd-analyze' (was: What's cooking in git.git (Oct 2021, #06; Mon, 25))

From
Eric Sunshine <sunshine@sunshineco.com>
Date
Oct 26, 2021, 18:43 UTC
Message-ID
<CAPig+cRMfzHA0vq6YHs4r3BU2UP6eBGvhb8mnEdeW7LB=E4z2w@mail.gmail.com>
In-Reply-To
<211026.864k93zteh.gmgdl@evledraar.gmail.com>

On Tue, Oct 26, 2021 at 11:40 AM Ævar Arnfjörð Bjarmason <avarab@gmail.com> wrote:

Show 12 quoted lines
> [...]
> So "fixing" that is easy, just have the prereq test that thing in
> particular, and why does one thing have a /lib/ prefix, but not the
> other?
>
> But presumably this points to a bigger problem. I.e. we just did a "git
> maintenance start" a few lines earlier.
>
> If I could start something via systemd then presumably it's either up,
> or our "start" is buggy and we didn't actually start something, or are
> using the wrong (non-portable?) invocation to check the running status
> of the thing we just started?

The bit you're missing is that the test script only mocks up starting and stopping the systemd unit:

    write_script print-args <<-\EOF &&
    printf "%s\n" "$*" >>args
    EOF
    GIT_TEST_MAINT_SCHEDULER="systemctl:./print-args" \
        git maintenance start --scheduler=systemd-timer &&

So, it's only running the `print-args` script, not actually invoking `systemctl`.

On the other hand, the "analyze" check really is invoking a real systemd command. (Why `systemd-analyze` needs to open /dev/tty0 explicitly rather than just emitting to stdout or stderr is a different question...)

Show 8 quoted lines
> Also aside from that shouldn't this be:
>
>     test_when_finished "systemd-something stop-it some-service" &&
>     systemd-something start-it some-service &&
>     [...]
>
> Or are runaway services handled somehow by systemd magic (tied to the
> PID of the test run?).

Answered above: we're just mocking starting/stopping the unit, not actually launching any background services.

Previous: Ævar Arnfjörð BjarmasonNext: Ævar Arnfjörð Bjarmason
Message 8 of 32 in “What's cooking in git.git (Oct 2021, #06; Mon, 25)”
  1. Junio C HamanoOct 26, 2021
  2. Jeff KingOct 26, 2021
  3. Junio C HamanoOct 27, 2021
  4. Kaartic SivaraamOct 31, 2021
  5. Jeff KingNov 1, 2021
  6. pre-v2.34.0-rc0 regressions: t7900-maintenance.sh broken due to 'systemd-analyze' (was: What's cooking in git.git (Oct 2021, #06; Mon, 25))Ævar Arnfjörð Bjarmason, Oct 26, 2021
  7. Ævar Arnfjörð BjarmasonOct 26, 2021
  8. Eric SunshineOct 26, 2021
  9. maintenance tests: fix systemd v2.34.0-rc* test regressionÆvar Arnfjörð Bjarmason, Nov 2, 2021
  10. Eric SunshineNov 3, 2021
  11. maintenance tests: fix systemd v2.34.0-rc* test regressionÆvar Arnfjörð Bjarmason, Nov 10, 2021
  12. Johannes SchindelinNov 10, 2021
  13. Ævar Arnfjörð BjarmasonNov 10, 2021
  14. Junio C HamanoNov 11, 2021
  15. pre-v2.34.0-rc0 regressions: 'git log' has a noisy iconv() warning (was: What's cooking in git.git (Oct 2021, #06; Mon, 25))Ævar Arnfjörð Bjarmason, Oct 26, 2021
  16. Jeff KingOct 27, 2021
  17. Junio C HamanoOct 27, 2021
  18. Jeff KingOct 28, 2021
  19. Junio C HamanoOct 28, 2021
  20. Jeff KingOct 28, 2021
  21. tb/plug-pack-bitmap-leaks (was: What's cooking in git.git (Oct 2021, #06; Mon, 25))Ævar Arnfjörð Bjarmason, Oct 26, 2021
  22. Taylor BlauOct 26, 2021
  23. jc/branch-copy-doc (was: What's cooking in git.git (Oct 2021, #06; Mon, 25))Ævar Arnfjörð Bjarmason, Oct 26, 2021
  24. Derrick StoleeOct 26, 2021
  25. Ævar Arnfjörð BjarmasonOct 26, 2021
  26. Victoria DyeOct 26, 2021
  27. Junio C HamanoOct 26, 2021
  28. Junio C HamanoOct 26, 2021
  29. Derrick StoleeOct 26, 2021
  30. regression in ns/tmp-objdir and ns/batched-fsyncNeeraj Singh, Oct 26, 2021
  31. Martin ÅgrenOct 27, 2021
  32. Junio C HamanoOct 28, 2021

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.