{"thread":{"id":"56584","subject":"New built-in fsmonitor: messages accidentally on stdout?","startedAt":"2021-09-24T18:03:02Z","lastAt":"2021-10-05T08:43:58Z","messageCount":4,"participants":["Tao Klerks","Jeff Hostetler","Johannes Schindelin"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"436992","messageId":"CAPMMpoj-oiD1yDHx6WS_1uiPOXMLj7FcfBPZm-q4vO30kpE_ow@mail.gmail.com","threadId":"56584","inReplyTo":null,"subject":"New built-in fsmonitor: messages accidentally on stdout?","fromName":"Tao Klerks","fromEmail":"tao@klerks.biz","sentAt":"2021-09-24T18:02:48Z","receivedAt":"2021-09-24T18:03:02Z","isPatch":false,"sender":{"key":"tao@klerks.biz","avatar":"https://avatars.githubusercontent.com/u/531704?v=4"},"body":"Hi folks,\n\nI've been testing the new \"core.usebuiltinfsmonitor=true\" capability\nin Git for Windows 2.33.0.windows.2, and came across something today\nthat threw off my scripting:\n\nIn general, git \"informational\" messages are always output on stderr;\nthis caught me out initially, but is a godsend for scripting.\n\nHowever, with this new functionality, the \"starting fsmonitor-daemon\nin 'C:/whatever\" message is being output on stdout!\n\nThis interferes with scripting around things like \"git status --porcelain\".\n\nI understand this fsmonitor stuff is still somewhat in-flux (patched\ninto the windows port but not yet \"regular\" git releases?), and this\nissue may already have been reported and addressed in the latest set\nof patches - my apologies if that is the case!\n\nBest regards,\nTao\n"},{"id":"437123","messageId":"CAPMMpoic0Dt=5Z7GB7BG7CqwxAs49SPPDkdasUPvasvsPhr-tg@mail.gmail.com","threadId":"56584","inReplyTo":"CAPMMpoj-oiD1yDHx6WS_1uiPOXMLj7FcfBPZm-q4vO30kpE_ow@mail.gmail.com","subject":"Re: New built-in fsmonitor: messages accidentally on stdout?","fromName":"Tao Klerks","fromEmail":"tao@klerks.biz","sentAt":"2021-09-27T09:32:22Z","receivedAt":"2021-09-27T09:32:35Z","isPatch":false,"sender":{"key":"tao@klerks.biz","avatar":"https://avatars.githubusercontent.com/u/531704?v=4"},"body":"Hi folks,\n\nI did track down where that message was being issued onto stdout in\ngit-for-windows\n(https://github.com/git-for-windows/git/blob/main/builtin/fsmonitor--daemon.c),\nand I see that in the the latest version of the patch series it was\nalready switched to stderr\n(https://github.com/jeffhostetler/git/blob/f08a63e197a0efe4d8f0452893238b0d3156e669/builtin/fsmonitor--daemon.c).\n\nThe only remaining thing I can ask for, I guess, is that the next Git\nfor Windows release ideally include this change/fix, even though the\nbuilt-in fsmonitor is not in \"regular git\" at all yet?\n\nThanks,\nTao\n\n\nOn Fri, Sep 24, 2021 at 8:02 PM Tao Klerks <tao@klerks.biz> wrote:\n>\n> Hi folks,\n>\n> I've been testing the new \"core.usebuiltinfsmonitor=true\" capability\n> in Git for Windows 2.33.0.windows.2, and came across something today\n> that threw off my scripting:\n>\n> In general, git \"informational\" messages are always output on stderr;\n> this caught me out initially, but is a godsend for scripting.\n>\n> However, with this new functionality, the \"starting fsmonitor-daemon\n> in 'C:/whatever\" message is being output on stdout!\n>\n> This interferes with scripting around things like \"git status --porcelain\".\n>\n> I understand this fsmonitor stuff is still somewhat in-flux (patched\n> into the windows port but not yet \"regular\" git releases?), and this\n> issue may already have been reported and addressed in the latest set\n> of patches - my apologies if that is the case!\n>\n> Best regards,\n> Tao\n"},{"id":"437148","messageId":"c0ff1914-8bf2-fb10-ea74-d35cf86508a1@jeffhostetler.com","threadId":"56584","inReplyTo":"CAPMMpoic0Dt=5Z7GB7BG7CqwxAs49SPPDkdasUPvasvsPhr-tg@mail.gmail.com","subject":"Re: New built-in fsmonitor: messages accidentally on stdout?","fromName":"Jeff Hostetler","fromEmail":"git@jeffhostetler.com","sentAt":"2021-09-27T13:52:39Z","receivedAt":"2021-09-27T13:52:41Z","isPatch":false,"sender":{"key":"git@jeffhostetler.com","avatar":null},"body":"\n\nOn 9/27/21 5:32 AM, Tao Klerks wrote:\n> Hi folks,\n> \n> I did track down where that message was being issued onto stdout in\n> git-for-windows\n> (https://github.com/git-for-windows/git/blob/main/builtin/fsmonitor--daemon.c),\n> and I see that in the the latest version of the patch series it was\n> already switched to stderr\n> (https://github.com/jeffhostetler/git/blob/f08a63e197a0efe4d8f0452893238b0d3156e669/builtin/fsmonitor--daemon.c).\n> \n> The only remaining thing I can ask for, I guess, is that the next Git\n> for Windows release ideally include this change/fix, even though the\n> built-in fsmonitor is not in \"regular git\" at all yet?\n\nYes, I've fixed that in my branch to print to stderr (and also\nput it behind a feature flag).\n\nIf my current series does not make it into core Git in time\nfor the next release, we will update the experimental version\nin the next git-for-windows release.\n\nThanks,\nJeff\n"},{"id":"437963","messageId":"nycvar.QRO.7.76.6.2110051043110.395@tvgsbejvaqbjf.bet","threadId":"56584","inReplyTo":"CAPMMpoic0Dt=5Z7GB7BG7CqwxAs49SPPDkdasUPvasvsPhr-tg@mail.gmail.com","subject":"Re: New built-in fsmonitor: messages accidentally on stdout?","fromName":"Johannes Schindelin","fromEmail":"johannes.schindelin@gmx.de","sentAt":"2021-10-05T08:43:54Z","receivedAt":"2021-10-05T08:43:58Z","isPatch":false,"sender":{"key":"johannes.schindelin@gmx.de","avatar":"https://avatars.githubusercontent.com/u/127790?v=4"},"body":"Hi Tao,\n\nOn Mon, 27 Sep 2021, Tao Klerks wrote:\n\n> I did track down where that message was being issued onto stdout in\n> git-for-windows\n> (https://github.com/git-for-windows/git/blob/main/builtin/fsmonitor--daemon.c),\n> and I see that in the the latest version of the patch series it was\n> already switched to stderr\n> (https://github.com/jeffhostetler/git/blob/f08a63e197a0efe4d8f0452893238b0d3156e669/builtin/fsmonitor--daemon.c).\n>\n> The only remaining thing I can ask for, I guess, is that the next Git\n> for Windows release ideally include this change/fix, even though the\n> built-in fsmonitor is not in \"regular git\" at all yet?\n\nThe latest snapshot at\nhttps://wingit.blob.core.windows.net/files/index.html should include the\nlatest iteration of the FSMonitor feature.\n\nCiao,\nJohannes\n\n> On Fri, Sep 24, 2021 at 8:02 PM Tao Klerks <tao@klerks.biz> wrote:\n> >\n> > Hi folks,\n> >\n> > I've been testing the new \"core.usebuiltinfsmonitor=true\" capability\n> > in Git for Windows 2.33.0.windows.2, and came across something today\n> > that threw off my scripting:\n> >\n> > In general, git \"informational\" messages are always output on stderr;\n> > this caught me out initially, but is a godsend for scripting.\n> >\n> > However, with this new functionality, the \"starting fsmonitor-daemon\n> > in 'C:/whatever\" message is being output on stdout!\n> >\n> > This interferes with scripting around things like \"git status --porcelain\".\n> >\n> > I understand this fsmonitor stuff is still somewhat in-flux (patched\n> > into the windows port but not yet \"regular\" git releases?), and this\n> > issue may already have been reported and addressed in the latest set\n> > of patches - my apologies if that is the case!\n> >\n> > Best regards,\n> > Tao\n>\n"}]}