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

Re: t5401-update-hooks test failure

From
Shawn O. Pearce <spearce@spearce.org>
Date
Feb 10, 2010, 01:29 UTC
Message-ID
<20100210012935.GD28936@spearce.org>
In-Reply-To
<7vpr4eyqok.fsf@alter.siamese.dyndns.org>
Junio C Hamano <gitster@pobox.com> wrote:
Show 19 quoted lines
> "Shawn O. Pearce" <spearce@spearce.org> writes:
> 
> > The only way I can see this missing message happening is if the C
> > library isn't flushing the stdio buffer before the hook process
> > exits.  Given that the hook process is a /bin/sh shell script,
> > and its using echo to print its messages... I'm at a loss for how
> > to fix that in Git.
> >
> > Unless its the recv_sideband() somehow skipping a line.  But I
> > can't see it doing that.
> 
> The detection method of test is fooled by intermixed message.
> 
> This is what send.err has, and you grep for '^remote:' in it.
> 
> -- >8 --
> warning: updating the current branch
> warning: Updating the currently cheremote: STDERR pre-receive        
> ,
..
> But there indeed _is_ some skipping.  "Updating the currently che"
> is interrupted by the output from the pre-receive hook, and I do not see
> the remainder "cked out branch may cause confusion,\n" anywhere.
Uh.  I got the problem now, thanks.

What's going on is, other messages inside of builtin-receive-pack are being sent to stderr, while hook output is going over the multiplexed side-band through stdout, where its parsed and written to stderr by send-pack.

What I missed in my patch was changing all of these other messages inside of receive-pack to also go over the side-band #2 if we have use_sideband enabled.

Patch coming in a few minutes.
-- 
Shawn.
Previous: Junio C HamanoNext: Larry D'Anna
Message 28 of 45 in “git-push: fix an error message so it goes to stderr”
  1. 1/3 git-push: fix an error message so it goes to stderrLarry D'Anna, Feb 8, 2010
  2. 2/3 git-push: clean up some of the output from git push --porcelainLarry D'Anna, Feb 8, 2010
  3. Junio C HamanoFeb 8, 2010
  4. Junio C HamanoFeb 8, 2010
  5. Jeff KingFeb 8, 2010
  6. Larry D'AnnaFeb 8, 2010
  7. Junio C HamanoFeb 8, 2010
  8. Larry D'AnnaFeb 8, 2010
  9. git-push: clean up some of the output from git pushLarry D'Anna, Feb 8, 2010
  10. Junio C HamanoFeb 8, 2010
  11. Larry D'AnnaFeb 8, 2010
  12. Junio C HamanoFeb 8, 2010
  13. git-push: fix the documentation to explain all the status flagsLarry D'Anna, Feb 8, 2010
  14. Junio C HamanoFeb 9, 2010
  15. Junio C HamanoFeb 9, 2010
  16. Junio C HamanoFeb 9, 2010
  17. Larry D'AnnaFeb 9, 2010
  18. Junio C HamanoFeb 9, 2010
  19. Larry D'AnnaFeb 9, 2010
  20. Larry D'AnnaFeb 9, 2010
  21. Junio C HamanoFeb 9, 2010
  22. Larry D'AnnaFeb 9, 2010
  23. Shawn O. PearceFeb 9, 2010
  24. Nicolas PitreFeb 9, 2010
  25. Shawn O. PearceFeb 9, 2010
  26. Junio C HamanoFeb 9, 2010
  27. Junio C HamanoFeb 9, 2010
  28. Shawn O. PearceFeb 10, 2010
  29. Larry D'AnnaFeb 9, 2010
  30. Jeff KingFeb 10, 2010
  31. Larry D'AnnaFeb 10, 2010
  32. Tay Ray ChuanFeb 10, 2010
  33. Junio C HamanoFeb 8, 2010
  34. Jeff KingFeb 10, 2010
  35. Junio C HamanoFeb 11, 2010
  36. Jeff KingFeb 12, 2010
  37. 3/3 git-push: make git push --dry-run --porcelain exit with status 0 even if updates will be rejectedLarry D'Anna, Feb 8, 2010
  38. Junio C HamanoFeb 8, 2010
  39. Larry D'AnnaFeb 8, 2010
  40. Junio C HamanoFeb 9, 2010
  41. Larry D'AnnaFeb 10, 2010
  42. 4/4 git-push: make git push --dry-run --porcelain exit with status 0 even if updates will be rejectedLarry D'Anna, Feb 10, 2010
  43. Larry D'AnnaFeb 15, 2010
  44. Junio C HamanoFeb 15, 2010
  45. Junio C HamanoFeb 8, 2010

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.