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

Re: [PATCH] t6423: fix suppression of Git’s exit code in tests

From
Junio C Hamano <gitster@pobox.com>
Date
Feb 4, 2025, 13:08 UTC
Message-ID
<xmqqjza5x3go.fsf@gitster.g>
In-Reply-To
<20250204003815.61391-1-ayu.chandekar@gmail.com>
Ayush Chandekar <ayu.chandekar@gmail.com> writes:
> Do you see any other changes needed in this patch? Let me know if there's
> anything you want me to adjust, especially in my commit message. Since my 
> previous attempt wasn't very suitable.

If I were to change something, there are two minor things, but they are so minor that I'd be OK without these changes.

If this is supposed to be a part of microproject exchange (sorry, I lost track), then I am also OK to do the second (and hopefully final) iteration to give us a chance to practice.

If I were you and I chose to iterate one more time, I'd rephrase this
    This commit ensures that Git's exit status is correctly propogated by:
    - Avoiding pipes that suppress exit codes.
to more like
    Instead of placing a git command on the upstream side of a pipe,
    redirect its output to a file and process the file contents in
    two separate steps to avoid losing the exit status.
Also I'd not redirect into "uniq", i.e. instead of
	uniq <actual >tracked &&
I'd write
	uniq actual >tracked &&

but as discussed with Eric, this "better style" is not followed by existing code.

Previous: Ayush ChandekarNext: Ayush Chandekar
Message 6 of 9 in “t6423: fix suppression of Git���s exit code in tests”
  1. t6423: fix suppression of Git���s exit code in testsayu-ch, Feb 2, 2025
  2. Meet SoniFeb 2, 2025
  3. Eric SunshineFeb 2, 2025
  4. Junio C HamanoFeb 3, 2025
  5. Ayush ChandekarFeb 4, 2025
  6. Junio C HamanoFeb 4, 2025
  7. [GSOC][PATCH v2] t6422: avoid suppressing Git’s exit code in testsAyush Chandekar, Feb 5, 2025
  8. Junio C HamanoFeb 5, 2025
  9. Ayush ChandekarFeb 6, 2025

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.