On Mon, Apr 13, 2020 at 02:05:00PM +0200, Son Luong Ngoc wrote: > Hey folks, > > I am trying to write a simple git trace2 event collector and I notice > that when git doing git pull with trace events being sent to a unix > stream socket, the entire operation halted. > > Reproduce as follow: > ``` > cd git/git > git config trace2.eventTarget af_unix:stream:/tmp/git_trace.sock > git config trace2.eventBrief false > (rm /tmp/git_trace.sock | ) && nc -lkU /tmp/git_trace.sock I doubt that this is important (for a reason that I'll point out below), but it looks like your invocation here is malformed with the trailing pipe character. Did you mean to redirect the output of rm away? If so, '2>&1 >/dev/null' will do what you want. > # In a different terminal > git pull # Pull stuck and never complete > ``` Odd. From my memory, trace2 will give up trying to connect to the socket (disabling itself and optionally printing a warning) if 'socket(2)' or 'connect(2)' set the error bit. My guess above is that you don't have a listening socket (because your shell is waiting for you to close the '|'), so there's no connection to be made. > This does not happen when you set eventBrief to true > ``` > git config trace2.eventBrief true > ``` Odd. What version of Git are you using? Your description makes it sound like it may be a bug, so I'd be curious to hear Jeff's interpretation of things, too. > Worth to note that if eventTarget is a file instead of a socket, > everything works fine. > > Cheers, > Son Luong. Thanks, Taylor