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

Re: [PATCH 2/2] ci: avoid ugly "failure" in the `ci-config` job

From
Jeff King <peff@peff.net>
Date
Sep 2, 2020, 00:40 UTC
Message-ID
<20200902004030.GC3294015@coredump.intra.peff.net>
In-Reply-To
<b92374e69192d57bcb11fb2573beb4e9aee339a9.1598991568.git.gitgitgadget@gmail.com>
On Tue, Sep 01, 2020 at 08:19:27PM +0000, Johannes Schindelin via GitGitGadget wrote:
Show 17 quoted lines
> From: Johannes Schindelin <johannes.schindelin@gmx.de>
> 
> In the common case where users have _not_ pushed a `ci-config` branch to
> configure which branches should be included in the GitHub workflow runs,
> there is a big fat ugly annotation about a failure in the run's log:
> 
> 	X Check failure on line 1 in .github
> 
> 	  @github-actions github-actions / ci-config
> 
> 	  .github#L1
> 
> 	  Process completed with exit code 128.
> 
> The reason is that the `ci-config` job tries to clone that `ci-config`
> branch, and even if it is configured to continue on error, the
> annotation is displayed, and it is distracting.

Hmm. I thought we handled this with the "continue-on-error" flag. Unsurprisingly I have a ci-config branch in my repo, but git/git doesn't, and here's a sample run there:

  https://github.com/git/git/runs/1053619435?check_suite_focus=true

Both the "ci-config" task, as well as the individual "try to clone ci-config branch" step are marked with a green check.

...Oh, I think I see what you mean. In the "Annotations" summary we still see an ugly "X" box.

> Let's just handle this on the shell script level, so that the job's step
> is not marked as a failure.

OK, that makes sense. We could do differentiate clone failing versus cd versus checkout (or for that matter, clone failing because the branch doesn't exist versus a network error). But it's probably not worth getting too fancy.

My next question was going to be: should we also drop the continue-on-error flag? But I see you did that already.

So the patch looks good to me. Sorry for introducing CI noise in the first place. :)

-Peff
Previous: Johannes Schindelin via GitGitGadgetNext: Junio C Hamano
Message 5 of 6 in “ci: avoid ugly "failure" annotation in the GitHub workflow”
  1. 0/2 ci: avoid ugly "failure" annotation in the GitHub workflowJohannes Schindelin via GitGitGadget, Sep 1, 2020
  2. 1/2 ci: fix indentation of the `ci-config` jobJohannes Schindelin via GitGitGadget, Sep 1, 2020
  3. Jeff KingSep 2, 2020
  4. 2/2 ci: avoid ugly "failure" in the `ci-config` jobJohannes Schindelin via GitGitGadget, Sep 1, 2020
  5. Jeff KingSep 2, 2020
  6. Junio C HamanoSep 2, 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.